zsh-workers
 help / color / mirror / code / Atom feed
From: Peter Stephenson <p.w.stephenson@ntlworld.com>
To: Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: "functions -c" and TRAPxxx
Date: Thu, 9 Jun 2022 09:55:13 +0100 (BST)	[thread overview]
Message-ID: <1500085568.729173.1654764913871@mail2.virginmedia.com> (raw)
In-Reply-To: <CAH+w=7ZJJv4KEXdW=2Pgqk+1YxjrmwX-HA5EBo00ZPgfM6N=gg@mail.gmail.com>

> On 09 June 2022 at 04:24 Bart Schaefer <schaefer@brasslantern.com> wrote:
> On Tue, Jun 7, 2022 at 7:57 AM Bart Schaefer <schaefer@brasslantern.com> wrote:
> >
> > I know most of what's going on there, but "functions -c" is creatin
> > an alternate name, and there is also the failure case of settrap()
> > returning nonzero to handle.
> 
> The following works for the case of settrap() succeeding, but I'm not
> sure how to force settrap() to fail.

Looks entirely plausible; given TRAP{INT,QUIT} already work this ought
to work too.

Looks like the only way for settrap to fail is using a signal number
that's not handled interactively.

pws


  reply	other threads:[~2022-06-09  8:55 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-07  1:59 Bart Schaefer
2022-06-07  9:57 ` Peter Stephenson
2022-06-07 14:57   ` Bart Schaefer
2022-06-09  3:24     ` Bart Schaefer
2022-06-09  8:55       ` Peter Stephenson [this message]
2022-06-09 15:19         ` Bart Schaefer
2022-06-09 20:51           ` Bart Schaefer

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=1500085568.729173.1654764913871@mail2.virginmedia.com \
    --to=p.w.stephenson@ntlworld.com \
    --cc=zsh-workers@zsh.org \
    --subject='Re: "functions -c" and TRAPxxx' \
    /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

Code repositories for project(s) associated with this 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).