zsh-users
 help / color / mirror / code / Atom feed
From: Sebastian Gniazdowski <sgniazdowski@gmail.com>
To: Bart Schaefer <schaefer@brasslantern.com>
Cc: Zsh Users <zsh-users@zsh.org>
Subject: Re: Suppress print_exit_value for single function
Date: Fri, 4 May 2018 18:29:44 +0200	[thread overview]
Message-ID: <CAKc7PVAP6cGkC=Bh6rHwmJUWyzsOHNcEFhO=Kh1f99XzP5XE6g@mail.gmail.com> (raw)
In-Reply-To: <180429120250.ZM3463@torch.brasslantern.com>

[-- Attachment #1: Type: text/plain, Size: 955 bytes --]

On 29 April 2018 at 21:02, Bart Schaefer <schaefer@brasslantern.com> 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

  parent reply	other threads:[~2018-05-04 16:30 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-29 18:42 Sebastian Gniazdowski
2018-04-29 19:02 ` Bart Schaefer
2018-04-30  2:21   ` Sebastian Gniazdowski
2018-04-30  2:23     ` Sebastian Gniazdowski
2018-05-04 16:29   ` Sebastian Gniazdowski [this message]
2018-05-05 15:10 ` Daniel Shahaf
2018-05-05 16:11   ` Sebastian Gniazdowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAKc7PVAP6cGkC=Bh6rHwmJUWyzsOHNcEFhO=Kh1f99XzP5XE6g@mail.gmail.com' \
    --to=sgniazdowski@gmail.com \
    --cc=schaefer@brasslantern.com \
    --cc=zsh-users@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).