zsh-workers
 help / color / mirror / code / Atom feed
* `=' expansion causes script/subshell to exit, bug?
@ 2018-09-27 19:20 Vasiliy Ivanov
  2018-09-27 19:41 ` dana
  2018-09-27 22:38 ` Mikael Magnusson
  0 siblings, 2 replies; 5+ messages in thread
From: Vasiliy Ivanov @ 2018-09-27 19:20 UTC (permalink / raw)
  To: zsh-workers

Hello. Recently I've seen that line like

[[ -x =somebinary ]] || cmd

causes script to exit unexpectedly with message like «/path/to/script:$line: =somebinary not found»,
instead of invoking || cmd and continue executing

some simple tests:

% ( [[ -x =123123 ]] || { print 'ohshi'; exit 2 } )
zsh: 123123 not found <exit code 1>

% ( b=123123; print =$b; print 'ohshi' )                                                  ↑
zsh: 123123 not found

Is it intended behaviour?

% zsh --version
zsh 5.6.2 (x86_64-pc-linux-gnu)

-- 
Regards,
  Vasiliy Ivanov <beelzebubbie.logs@gmail.com>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-09-27 22:38 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-27 19:20 `=' expansion causes script/subshell to exit, bug? Vasiliy Ivanov
2018-09-27 19:41 ` dana
2018-09-27 20:33   ` Bart Schaefer
2018-09-27 20:37     ` dana
2018-09-27 22:38 ` Mikael Magnusson

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).