Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: OPTARG not being set?
- X-seq: zsh-users 2068
- From: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxxxxxxx
- Subject: Re: OPTARG not being set?
- Date: Wed, 3 Feb 1999 00:23:29 -0800
- Cc: Sweth Chandramouli <sweth@xxxxxxxxxxxxxxxxxxxx>
On Feb 3, 12:03am, Bart Schaefer wrote:
} Subject: Re: OPTARG not being set?
}
} If instead you said $(echo "echo \${$(echo ${bob})}"), then the \$ is not
} converted into bare $, and the string becomes "echo \${joe}", and the
} result of the whole expression is
}
} ${joe}
One point of additional clarity: As I said, the \$ is not converted to $
when the outer $(echo ...) is parsed; but $(echo ${bob}) is substituted
when the quoted string is parsed, which is how it becomes "echo \${joe}".
Then, although the backslash is then finally stripped, the $ becomes a
quoted character (because of appearing inside quotes), and is thus not
lexed as the start of a substitution when the string produced by the outer
$(echo ...) is finally executed.
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Messages sorted by:
Reverse Date,
Date,
Thread,
Author