Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
sh compatibility RE: PATCH: pws-19: document minor syntactic innovation
- X-seq: zsh-workers 6434
- From: "Andrej Borsenkow" <borsenkow.msk@xxxxxx>
- To: "Peter Stephenson" <pws@xxxxxxxxxxxxxxxxx>, "Zsh hackers list" <zsh-workers@xxxxxxxxxxxxxx>
- Subject: sh compatibility RE: PATCH: pws-19: document minor syntactic innovation
- Date: Wed, 2 Jun 1999 12:44:50 +0400
- Importance: Normal
- In-reply-to: <9906020803.AA37683@xxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
>
> This is the patch below; ${"foo"%bar} will now work. There are still
> probably lots of other possible places, but I don't think it's worth
> searching for them; if it seems sensible to allow quotes there, someone
> will notice at some point.
>
How compatible with shell is it?
bor@itsrm2:~%> foo=bar
bor@itsrm2:~%> print $"foo"
$foo
bor@itsrm2:~%> print ${"foo"}
bar
bor@itsrm2:~%> print ${"bar":-com}
but
bor@itsrm2:~%> /sbin/xpg4/sh (for what it's worth :-)
$ foo=bar
$ print $"foo"
$foo
$ print ${"foo"}
/sbin/xpg4/sh: ${"foo"}: bad substitution
$ print ${"bar":-com}
/sbin/xpg4/sh: ${"bar":-com}: bad substitution
Messages sorted by:
Reverse Date,
Date,
Thread,
Author