Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] _file_descriptors: initialize `list' array with local -a
- X-seq: zsh-workers 35505
- From: Oliver Kiddle <okiddle@xxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: [PATCH] _file_descriptors: initialize `list' array with local -a
- Date: Wed, 17 Jun 2015 16:57:49 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.co.uk; s=s2048; t=1434553070; bh=kd6tJ2hVM7MJUPRKcftVpit98Sm7GpKV+/KSfl6LMLc=; h=In-reply-to:From:References:To:Subject:Date:From:Subject; b=C3iyA5uWXMEWba8dQDr3cq62hT2fr9+k9LkRk7ztmL/Qo58+BScJiB1b4CDDJ8Ahv3ygivM7p0G7it62nNL2aydMe9IvoKckk3j50Zo4JG1Q5uObP5XrP7TvSsuAEVFaTn/ozwBcW6cyU2Mt1AKnUhoNB7VxQJJlXHx/f7LJ1BvPMEPkVQbVuDMGGVOuBBq5Qiix4nl9FPI0JXD7TpemyQ1X4uJFLatDBgcNGRKGhbFxTFQ4pCVMQaA7x7scbef9ecwuht9b+lruj3FcT3IN/pSWx/8Y96kh0jZLdnycgbhM9XgfKXSeyXs1dZWiXohuD6MSAfHnD0avVZVGvNl1WQ==
- In-reply-to: <558047B6.4090908@gmx.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <1434432668-18303-1-git-send-email-llua@gmx.com> <22433.1434440572@thecus.kiddle.eu> <558047B6.4090908@gmx.com>
Eric Cook wrote:
> Question: is there a reason why the upper limit is fd9?
Because redirections don't let you use two-digit numbers.
However, the {var} syntax will allocate higher numbered file
descriptors so the limitation is out-of-date and can probably be
ignored.
The updated function looks good. One slight issue is that description
separators don't align now that two digit fds are included:
0 -- standard input
1 -- standard output
10 -- /dev/pts/6
zformat can do that in the general case but you might get away with
"${(r.$#fds[-1].)i} $sep ...
We have worse examples of that such as git subcommands.
Oliver
Messages sorted by:
Reverse Date,
Date,
Thread,
Author