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

Re: Suppress print_exit_value for single function

On 29 April 2018 at 21:02, Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:

> On Apr 29,  8:42pm, Sebastian Gniazdowski wrote:
> }
> } Can I block `setopt print_exit_value' effects for this sched function or
> to
> } all sched functions in general?
> You can always
>   setopt localoptions no_print_exit_value

Can it be true that the C array of structures, `funcstack':

typedef struct funcstack *Funcstack;

will have something distinct for function ran from sched? The
print_exit_value code would be then able to easily check for this distinct
trait. I think all this is worth doing, not for aesthetics aspect, but to
allow background functions to maintain $? unchanged (and e.g. repeat
erroneous exit code). It is a poor situation currently, e.g. syntax
highlighting runs after key press and $? is lost, it cannot be directly
used at command line. Lets do something to address this, at least for sched.

Best regards,
Sebastian Gniazdowski

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