unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Philipp Stephani <p.stephani2@gmail.com>
Cc: phst@google.com, emacs-devel@gnu.org
Subject: Re: [PATCH] Ignore pending_signals when checking for quits.
Date: Thu, 03 Jan 2019 16:03:14 +0200	[thread overview]
Message-ID: <83sgy93kkd.fsf@gnu.org> (raw)
In-Reply-To: <20190102212218.74902-1-phst@google.com> (message from Philipp Stephani on Wed, 2 Jan 2019 22:22:18 +0100)

> From: Philipp Stephani <p.stephani2@gmail.com>
> Date: Wed,  2 Jan 2019 22:22:18 +0100
> Cc: Philipp Stephani <phst@google.com>
> 
>  static bool
>  module_should_quit (emacs_env *env)
>  {
>    MODULE_FUNCTION_BEGIN_NO_CATCH (false);
> -  return (! NILP (Vquit_flag) && NILP (Vinhibit_quit)) || pending_signals;
> +  return QUITP;
>  }

Bother.  I see your point regarding the return value when just
pending_signals is set, but disregarding pending_signals doesn't sound
TRT to me, either.  It means various Emacs features based on input
detection won't work while the module code runs, even if the module
tries to be nice and does call module_should_quit.  For example,
while-no-input and atimers won't work, and Emacs will generally be
much less responsive to user input.

So maybe we should indeed return true only if QUITP says so, but we
should also call process_pending_signals from module_should_quit, when
pending_signals is non-zero?



  reply	other threads:[~2019-01-03 14:03 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-02 21:22 [PATCH] Ignore pending_signals when checking for quits Philipp Stephani
2019-01-03 14:03 ` Eli Zaretskii [this message]
2019-02-10 18:49   ` Philipp Stephani
2019-02-10 19:40     ` Eli Zaretskii
2019-02-10 19:46       ` Philipp Stephani
2019-02-10 20:15         ` Eli Zaretskii
2019-02-11 20:17           ` Philipp Stephani
2019-02-13 15:28             ` Eli Zaretskii
2019-02-24 21:51               ` Philipp Stephani
2019-04-19 19:06                 ` Philipp Stephani
2019-04-19 20:15                   ` Eli Zaretskii
2019-04-28 18:19                     ` Philipp Stephani
2019-04-28 18:42                       ` Eli Zaretskii
2019-08-07 16:22                         ` Philipp Stephani
2019-01-03 14:09 ` Eli Zaretskii

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=83sgy93kkd.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=p.stephani2@gmail.com \
    --cc=phst@google.com \
    /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.savannah.gnu.org/cgit/emacs.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).