Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: creating associative arrays
- X-seq: zsh-users 4539
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: "Akos Szalkai" <szalkai@xxxxxxxxx>, zsh-users@xxxxxxxxxx
- Subject: Re: creating associative arrays
- Date: Fri, 14 Dec 2001 16:31:02 +0000
- In-reply-to: <20011211194522.A8605@xxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20011211194522.A8605@xxxxx> <4466.1008152926@xxxxxxx> <20011212133053.B251@xxxxx>
On Dec 11, 7:45pm, Akos Szalkai wrote:
}
} I am trying to fill an associative array from a file. If the name of
} the file is fixed, e.g. array.txt then the following works:
}
} : ${(AA)dict::=$(<array.txt)}
}
} However, if the filename is given in a parameter then the command:
} : ${(AA)dict::=$(<${filename})}
} gives the error
} zsh: bad set of key/value pairs for associative array.
This is a side-effect of the bug that was fixed in zsh-workers/16215.
That was about a week after the 4.0.4 release; the above works in the
latest 4.1.0-dev. I haven't committed that patch on the 4.0 branch yet.
[Unrelated admin note: My ISP is playing games with me again, so any
mail directed to schaefer@xxxxxxxxxxxxxxxxxxxxxxx or to any other third-
or greater-level domain in brasslantern.com, will bounce. Mail sent to
schaefer@xxxxxxxxxxxxxxxx will get through.]
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net
Messages sorted by:
Reverse Date,
Date,
Thread,
Author