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

Re: Bug#526925: zparseopts: '+' option is being ignored with normal arrays



On Mon, May 04, 2009 at 03:04:38PM +0200, martin f krafft wrote:
> piper:~|master|% set -- -a1 -a2; zparseopts a+:=arr; echo $arr
> 2
> 
> The + option is supposed to ensure that all occurrences get appended
> to the array, not just the last one. Apparently, the same problems
> occurs when a global array is used:
> 
> piper:~|master|% set -- -a1 -a2; zparseopts -a arr a+:; echo $arr
> 2

Oddly, here I get

-a 1 -a 2

and the last issue was only because I forgot to use a -- after print -l.



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