Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Parameter expansion/substitution rules
- X-seq: zsh-workers 5870
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: Parameter expansion/substitution rules
- Date: Mon, 22 Mar 1999 11:15:58 +0100 (MET)
- In-reply-to: "Bart Schaefer"'s message of Sat, 20 Mar 1999 14:29:33 -0800
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
Bart Schaefer wrote:
> The new section on expansion rules should mention when the (e) and (P)
> flags kick in. I considered producing a patch for this but then decided
> I wasn't sure I would get it right. (e) happens after rule 6, and then
> padding from the (l) and (r) flags is inserted last of all; but I'm not
> sure when (P) happens, or what happens with (eP) both given at once.
(P) is used very early, after subscripting, before other
modifications. The fact that subscripting is done on the value of the
original parameter is slightly irritating, but one can always use
`${(P)${foo}[1]}' to make the subscript apply to the value of the
parameter that is finally used.
With (eP), the (e) is still aplied at the end, as always (i.e. there
is no special treatment for the combination).
Bye
Sven
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author