Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: OPTARG not being set?
- X-seq: zsh-users 2065
- From: Sweth Chandramouli <sweth@xxxxxxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxxxxxxx
- Subject: Re: OPTARG not being set?
- Date: Tue, 2 Feb 1999 22:56:46 -0500
On Tue, Feb 02, 1999 at 09:52:45AM +0100, Bernd Eggink wrote:
> Options with arguments are denoted as "p:". ":p" has a different
> meaning; see "man zshbuiltins".
ah yes, the revenge of the glaringly obvious typo.
my next question, then, is why the following occurs:
(astaroth)~1: joe='hello world'
(astaroth)~2: bob=joe
(astaroth)~3: echo ${joe}
hello world
(astaroth)~4: echo ${bob}
joe
(astaroth)~5: echo ${${bob}}
joe
(astaroth)~6: echo ${(e)bob}
joe
(astaroth)~7: echo "echo \${$(echo ${bob})}"
echo ${joe}
(astaroth)~8: `echo "echo \${$(echo ${bob})}"`
joe
(astaroth)~9: echo ${ZSH_VERSION}
3.1.5
i would think that #5 should print hello world,
that #6 would explicitly cause parameter expansion and
print hello world, and that #8 would evaluate the results
of #7, which would be the same as typing #3, and would
thus print hello world.
-- sweth.
--
Sweth Chandramouli
IS Coordinator, The George Washington University
<sweth@xxxxxxx> / (202) 994 - 8521 (V) / (202) 994 - 0458 (F)
<a href="http://astaroth.nit.gwu.edu/~sweth/disc.html">*</a>
Messages sorted by:
Reverse Date,
Date,
Thread,
Author