Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Using file lines as "input files"
- X-seq: zsh-users 27886
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: Using file lines as "input files"
- Date: Sun, 10 Jul 2022 10:49:49 -0700
- Archived-at: <https://zsh.org/users/27886>
- In-reply-to: <CAH+w=7aXO2bvU_XAJWqL9a4bNWtbnLpE-D878AKiT3Xe71MnUA@mail.gmail.com>
- List-id: <zsh-users.zsh.org>
- References: <Ysiacl2I2eYF+uY4@gmx.de> <CAH+w=7betuB2tG+RrkYiqsQ66_3xKwfK1kSkVyY-SBRcVjqhvQ@mail.gmail.com> <Ysi7JTBpUXK/F8v/@gmx.de> <CAHYJk3T9G+VZO9prf_qm2P4yAYVJ-qi_urSBzGTWDhnn9dPTdw@mail.gmail.com> <YsogYlt8Tfpjc6PI@gmx.de> <CAH+w=7aXO2bvU_XAJWqL9a4bNWtbnLpE-D878AKiT3Xe71MnUA@mail.gmail.com>
On Sat, Jul 9, 2022 at 8:27 PM Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
>
> The leading "nonexistent" elements become one word, and the remaining
> element with a value becomes another. I'm not sure why that happens.
In fact any series of "unset" elements becomes an (empty) word.
% foo[9]=x
% foo[18]=''
% unset foo\[18\]
% print $#foo
18
% setopt shwordsplit
% print a${^foo}b
ab axb ab
Messages sorted by:
Reverse Date,
Date,
Thread,
Author