Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: sh compatibility again :->
- X-seq: zsh-workers 1944
- From: Andrej Borsenkow <borsenkow.msk@xxxxxx>
- To: schaefer@xxxxxxx
- Subject: Re: sh compatibility again :->
- Date: Mon, 12 Aug 1996 10:20:09 +0400 (MOW)
- Cc: Zoltan Hidvegi <hzoli@xxxxxxxxxx>, zsh-workers@xxxxxxxxxxxxxxx
- In-reply-to: <960811213634.ZM4881@xxxxxxxxxxxxxxxxxxxxxxx>
- Reply-to: borsenkow.msk@xxxxxx
On Sun, 11 Aug 1996, Bart Schaefer wrote:
>
> } > But the following things could probably be fixed
> } >
> } > 4. Traditional /bin/sh interprets `set -' as set +xv.
> }
> } OK. I've changed that. set - will be the same as set +xv and
> } set - args will be the same as set +xv -- args.
>
> Hmm. So what's the approved way of setting $1 to "-x"? `set -- -x`?
> And is `set --` equivalent to `shift $#`, since `set -` is not?
>
> Are you sure `set - args` should act like `set +xv -- args`?
>
Well, /bin/sh behaves execatly this way.
> I can't say I'm entirely excited about this change.
>
It is lonely `set -' which have this effect. Just the same, as lonely `set
+' does *not* sets $1 to + but rather outputs all parameter names. If I
try `set + foo', it sets $1 to `foo'. So `set -' could just follow the
suit.
Greetings
-------------------------------------------------------------------------
Andrej Borsenkow Fax: +7 (095) 252 01 05
SNI ITS Moscow Tel: +7 (095) 252 13 88
NERV: borsenkow.msk E-Mail: borsenkow.msk@xxxxxx
-------------------------------------------------------------------------
Messages sorted by:
Reverse Date,
Date,
Thread,
Author