zsh-users
 help / color / mirror / code / Atom feed
* multi-digit file descriptors
@ 2015-02-11 16:26 Vincent Lefevre
  2015-02-11 17:27 ` Bart Schaefer
  0 siblings, 1 reply; 8+ messages in thread
From: Vincent Lefevre @ 2015-02-11 16:26 UTC (permalink / raw)
  To: zsh-users

Contrary to bash and mksh, zsh doesn't support file descriptors with
multiple digits. Considered the following file "redir".

----------------------------------------
( echo foo >&9; ) 9>my_file
cat my_file

( echo bar >&10; ) 10>my_file
cat my_file
----------------------------------------

xvii% bash redir
foo
bar
xvii% mksh redir
foo
bar
xvii% zsh redir
foo
redir:4: parse error near `10'

The behavior of dash and ksh93 is similar to zsh. But is there any
reason?

BTW, POSIX doesn't seem to restrict file descriptors to 1 digit.

-- 
Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)


^ permalink raw reply	[flat|nested] 8+ messages in thread
[parent not found: <20150211162637.GA9083__22180.4416658872$1423672129$gmane$org@xvii.vinc17.org>]

end of thread, other threads:[~2015-02-13  4:21 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-11 16:26 multi-digit file descriptors Vincent Lefevre
2015-02-11 17:27 ` Bart Schaefer
2015-02-11 17:46   ` Peter Stephenson
2015-02-12 10:24     ` Vincent Lefevre
2015-02-12 16:45       ` Bart Schaefer
2015-02-12 10:16   ` Vincent Lefevre
2015-02-13  4:21     ` Bart Schaefer
     [not found] <20150211162637.GA9083__22180.4416658872$1423672129$gmane$org@xvii.vinc17.org>
2015-02-11 20:47 ` Stephane Chazelas

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).