Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: mailcheck patch



> Zoltan wrote:
> > I do not incorporate it now.  Instead here is an other patch.  After that,
> > the message part of mailpath will undergo parameter expansion, command
> > substitution and arithmetic substitution.  This is exactly what ksh does.
> > This can provide equivalent functionality to the requested feature.
> 
> Fine by me. Just to check, though, is it clear that $_ will never clash with
> its normal "special parameter" meaning?

During the substitution the $_ special parameter expands to the name of the
mail folder.  The old value of $_ is saved before the expansion and
restored afterwards.  In command substitutions only the first command can
use $_ this way but that is not a big limitation.  Command substitutions
are evaluated after a fork() and the change in $_ does not affect the
parent process.

Zoltan




Messages sorted by: Reverse Date, Date, Thread, Author