zsh-workers
 help / color / mirror / code / Atom feed
From: "Daniel Shahaf" <d.s@daniel.shahaf.name>
To: zsh-workers@zsh.org
Subject: Re: { exit } always { foo }
Date: Thu, 19 Dec 2019 16:05:03 +0000	[thread overview]
Message-ID: <5c399b50-83b5-4541-b5be-56106ffb4e87@www.fastmail.com> (raw)
In-Reply-To: <1576769851.4486.16.camel@samsung.com>

Peter Stephenson wrote on Thu, 19 Dec 2019 15:37 +00:00:
> On Thu, 2019-12-19 at 15:28 +0000, Daniel Shahaf wrote:
> > Daniel Shahaf wrote on Wed, 18 Dec 2019 05:23 +00:00:
> > > 
> > > So, personally, I would find it more intuitive to change the implementation to
> > > match the documentation, than the other way around.
> > I'll wait a bit more for feedback.  If the decision ends up being to change the
> > implementation to match the documentation, I'll at least document it as
> > a bug/incompatibility, or maybe fix it if I manage that.
> 
> I don't think it's that big a deal either way as long as the inconsistency
> gets fixed; I'd be happy to leave it to what ever feels most natural if you're
> using the feature in question.

I think there are actually two separate questions here:

- Whether 'return outside of any function' should be equivalent to 'exit'

- Whether the always-list should be run if the try-list does an exit

I'm not sure what my answers to these questions any more.

For that matter, should the always-list run if a SIGINT is received during the
try-list?  What about SIGQUIT?  The documentation only says the always-list
will be executed in case of "a condition such as a syntax error which causes
the shell to abort execution [...]".

Hmm…

Daniel

      reply	other threads:[~2019-12-19 16:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-18  3:56 Daniel Shahaf
2019-12-18  4:54 ` Bart Schaefer
2019-12-18  4:59   ` Bart Schaefer
2019-12-18  5:23   ` Daniel Shahaf
2019-12-19 15:28     ` Daniel Shahaf
2019-12-19 15:37       ` Peter Stephenson
2019-12-19 16:05         ` Daniel Shahaf [this message]

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=5c399b50-83b5-4541-b5be-56106ffb4e87@www.fastmail.com \
    --to=d.s@daniel.shahaf.name \
    --cc=zsh-workers@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).