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

Re: PATCH: 3.1.5 - sample associative array implementation



Peter Stephenson <pws@xxxxxxxxxxxxxxxxx> writes:

> This can probably be fixed in a perl-like fasion by adapting
> setarrvalue(), which should be reasonably painless, though I haven't
> looked at the details yet.  One question is whether
>   hash=(key1 val1 key2 val2)
> replaces the array entirely, or just adds/replaces those elements.  In
> the former case it's difficult to think of a way of replacing multiple
> elements at once; maybe another new typeset flag.

What does ksh93 provide in the way of associative array functionality?
(I don't have it installed at work, so I can't look it up right not.)

I'm not suggesting that ksh93 is always right about everything, but it
would surely be a good starting point, and a zsh which contained ksh93
as a subset would be much more convenient than having gratuitous
syntactic differences.  Except in those places where ksh93 is just
wrong, of course.



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