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

Possible bug with parameter expansion



The ${name:#pattern} form of parameter expansion doesn't work within
double quotes. It is acting as if the pattern matched all the elements.
The following should demonstrate:

% a=( a d=rt b=fg c e=yt )
% echo ${a:#*=*}
a c
% echo "${a:#*=*}"

% echo "${(M)a:#*=*}"
a d=rt b=fg c e=yt

This looks like a bug to me because I can't see why the double quotes
should be affecting the result.

Oliver



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