groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] Re: .substring bug - indicies don't work as documented(?)


From: Bernd Warken
Subject: Re: [Groff] Re: .substring bug - indicies don't work as documented(?)
Date: Sun, 28 Oct 2001 12:56:31 +0100
User-agent: Mutt/1.2.5i

On Sun, Oct 28, 2001 at 02:58:53AM +0100, Werner LEMBERG wrote:
> 
> I prefer the current syntax, i.e., no second argument (i.e., set to
> zero) means `take the rest'.  This is probably the very reason to make
> the last character have the index 0.
> 
Ok, this is logical.  No second arg means add 0.

> > It is illogical to start with 1 from the front and with 0 from the
> > end.  Moreover, 0 means everything up to behind the last character;
> > so the last character should be -1 anyway.
> 
> I agree, but I think it isn't worth the trouble.
> 
So add it to the TODO list.  I'm sure someone will do it one day.
troff has enough strange elements , so at least the groff extensions 
should make sense.

> > Also 2 args in reversed order could be made into reversing the
> > output.
> 
> Who needs that?
> 
I remember that some years ago, people argued against groff in that way.

The reasonable way to handle arguments in reversed order is to make it
something useful different from the usual order - or make it an error.
This will avoid confusion among the users.

Bernd Warken


reply via email to

[Prev in Thread] Current Thread [Next in Thread]