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

Re: PRINT_EXIT_VALUE: Suppress for if/while conditions



Peter Stephenson wrote on Fri, Aug 14, 2015 at 09:19:45 +0100:
> On Thu, 13 Aug 2015 23:20:20 +0000
> Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx> wrote:
> > I have no problem with ruling out the jobs/bg/fg callsites, as you
> > propose.  However, checking (synch == 1) would also mean the value of
> > PRINTEXITVALUE is entirely ignored when printjob() is called
> > asynchronously.  I can see that that is fine for jobs that don't have
> > STAT_NOPRINT set.¹  Is it also correct to ignore PRINTEXITVALUE in the
> > case (synch == 0 && (jn->stat & STAT_NOPRINT))?
> 
> My point is really that you don't want to *modify* the code unless synch
> == 1.  So sync == anything else should continue to do just what it does
> at the moment, but if synch == 1 you can apply your extra check.  That
> seems likely to do the nearest to what everybody wants.

I'll give that a shot.  (Was a bit busy so haven't coded it yet.)
Thanks again.



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