On 2024-03-21 02:38:10 +0100, Gioele Barabucci wrote:
> On Mon, 11 Feb 2008 13:20:25 +0100 Vincent Lefevre <vinc...@vinc17.org>
> wrote:
> > As a summary, the following test at least does not behave correctly:
> > 
> > vlefevre@vin:~$ test \( ! -e \) ; echo $?
> > bash: test: `)' expected
> > 2
> > 
> > And I think this one is also buggy:
> > 
> > vlefevre@vin:~$ test true -a \( ! -a \) ; echo $?
> > bash: test: `)' expected
> > 2
> > 
> > FYI, the coreutils and zsh test utility both output 1 on these tests;
> > so does dash on the second one only.

dash now gives 1 on both cases, as expected. But for the second one,
zsh now gives an error and 2 like bash; I would see this as a bug,
like for bash.

Note that

  $ test \( ! -a \) ; echo $?
  1

for both bash and zsh, so "test true -a \( ! -a \)" should really
behave in the same way.

-- 
Vincent Lefèvre <vinc...@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)

Reply via email to