zsh-workers
 help / color / mirror / code / Atom feed
* Bug? Output not flushed?
@ 2023-09-15 16:56 Bart Schaefer
  2023-09-15 17:05 ` Mikael Magnusson
  0 siblings, 1 reply; 5+ messages in thread
From: Bart Schaefer @ 2023-09-15 16:56 UTC (permalink / raw)
  To: Zsh hackers list

Easily reproduced:

% { print XXX; return 0; } >| /tmp/newfile; print $(</tmp/newfile)
% print $(</tmp/newfile)
XXX

That is, when a return statement appears in a current-shell complex
list, the output is not flushed until the parser reaches the top level
again.  If the return statement is removed, all is well:

% { print YYY; } >| /tmp/newfile; print $(</tmp/newfile)
YYY
%

Any idea where to start looking for this?


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

end of thread, other threads:[~2023-09-16  1:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-09-15 16:56 Bug? Output not flushed? Bart Schaefer
2023-09-15 17:05 ` Mikael Magnusson
2023-09-15 17:30   ` Bart Schaefer
2023-09-15 22:22     ` [PATCH] ? Parse error does not always set $? (Was: Bug? Output not flushed?) Bart Schaefer
2023-09-16  1:20       ` Bart Schaefer

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