Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

[bug] errexit and cmdsubst after "else"



From
https://unix.stackexchange.com/questions/565158/command-substitution-does-not-respect-err-exit-sometimes

$ zsh -ec 'if false; then;else a=$(false); echo $?; fi'
1

expected no output because of errexit.

That seems to be regression. @Gilles there bisected it to
https://sourceforge.net/p/zsh/code/ci/b581c3fece76c87ed86ae9fc704d0fcf208a79d3/

Which seemed to be a fix for a similar bug or regression:
http://www.zsh.org/cgi-bin/mla/redirect?WORKERNUMBER=36766

https://www.zsh.org/mla/workers/2015/msg02685.html

Possibly incomplete.

-- 
Stephane




Messages sorted by: Reverse Date, Date, Thread, Author