Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Change in FIGNORE behavior

Stephane Chazelas wrote:
> On Fri, Jun 15, 2007 at 11:09:06AM +0100, Peter Stephenson wrote:
> [...]
> >   array=(one two three)
> > 
> > With KSH_ZERO_SUBSCRIPT set (old behaviour):
> >   $array[0]               -> one
> >   array[(R)notfound]      -> one
> >   $array[0,2]             -> one two
> [...]
> Hi Peter,
> why not "one two three" there (0, 1, 2)?

You're thinking of the KSH_ARRAYS option, which does have the effect you
say.  The old behaviour of the shell as shown above really was
that inconsistent... if you asked for 0 or 1 you got "one", if you asked
for 2 you got "two", but if you asked for the range 0 to 2 you got not
0 and 1 and 2, but just 1 and 2.  That's why we want to remove that
behaviour (at least by default).

Peter Stephenson <pws@xxxxxxx>                  Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK                          Tel: +44 (0)1223 692070

To access the latest news from CSR copy this link into a web browser:  http://www.csr.com/email_sig.php

To get further information regarding CSR, please visit our Investor Relations page at http://ir.csr.com/csr/about/overview

Messages sorted by: Reverse Date, Date, Thread, Author