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

Re: associative array questions



On Tue, 13 Dec 2022 at 17:12, Ray Andrews <rayandrews@xxxxxxxxxxx> wrote:

local list=$1    # function takes name of array as argument.

eval 'list=( "${(@M)list:#(#i)*$SEARCHBUF*}" )'     # filter the array.

This eval will expand things that you don't want expanded. Use `set -A $list` instead.

Roman.


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