GNU bug report logs - #75729
[PATCH] python-mode: add `exit` to the list of block-enders

Previous Next

Package: emacs;

Reported by: Konstantin Kharlamov <Hi-Angel <at> yandex.ru>

Date: Tue, 21 Jan 2025 15:43:02 UTC

Severity: wishlist

Tags: patch

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #14 received at 75729 <at> debbugs.gnu.org (full text, mbox):

From: Konstantin Kharlamov <Hi-Angel <at> yandex.ru>
To: Ship Mints <shipmints <at> gmail.com>
Cc: 75729 <at> debbugs.gnu.org
Subject: Re: bug#75729: [PATCH] python-mode: add `exit` to the list of
 block-enders
Date: Tue, 21 Jan 2025 18:55:20 +0300
[Message part 1 (text/plain, inline)]
On Tue, 2025-01-21 at 10:47 -0500, Ship Mints wrote:
> Do you want to consider more of the terminal calls? os.exit()
> os._exit() sys.exit() quit() (though quit raises SystemExit which
> could be locally caught; I think it's equivalent to raise
> SystemExit?).
> 
> On Tue, Jan 21, 2025 at 10:43 AM Konstantin Kharlamov
> <Hi-Angel <at> yandex.ru> wrote:
> > `exit()` ends current codeflow, there can't be any code past it. So
> > account `exit` similarly to `return`, `continue`, etc.

Good point, thank you! I changed the patch to account for `quit` as
well.

If this is acceptable, I'd prefer to be light on the changes here and
only account for exit and quit for now because it's very simple to
support 😊

Also fixed the commit message per Eli's comment.
[1.patch (text/x-patch, attachment)]

This bug report was last modified 180 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.