From: Eli Zaretskii <eliz@gnu.org>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: 70221@debbugs.gnu.org
Subject: bug#70221: [PATCH] New function `funcall-later`
Date: Sat, 06 Apr 2024 09:36:00 +0300 [thread overview]
Message-ID: <86zfu73smn.fsf@gnu.org> (raw)
In-Reply-To: <jwvbk6nh9c7.fsf@iro.umontreal.ca> (bug-gnu-emacs@gnu.org)
> Date: Fri, 05 Apr 2024 15:56:40 -0400
> From: Stefan Monnier via "Bug reports for GNU Emacs,
> the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>
> +DEFUN ("internal--run-pending-funcalls", Frun_pending_funcalls, Srun_pending_funcalls, 0, 0, 0,
> + doc: /* Run the still pending `funcall-later'. */)
> + (void)
> +{
> + while (CONSP (pending_funcalls) || CONSP (pending_funcalls_r))
> + if (CONSP (pending_funcalls))
> + {
> + Lisp_Object funcall = XCAR (pending_funcalls);
> + pending_funcalls = XCDR (pending_funcalls);
> + CALLN (Fapply, funcall);
> + }
> + else
You are using CALLN here, whereas the previous implementation used
safe_calln. Is that intended? Calling Lisp in unsafe ways in that
place might not be a good idea. You didn't even inhibit QUIT.
As another difference between run-with-time and this mechanism, the
former took care of preserving deactivate-mark around the call, wheres
funcall-later doesn't -- this is at least one difference that we
should document (assuming we want it).
next prev parent reply other threads:[~2024-04-06 6:36 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-05 19:56 bug#70221: [PATCH] New function `funcall-later` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-05 20:49 ` Felician Nemeth
2024-04-05 22:44 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-06 6:59 ` Eli Zaretskii
2024-04-06 8:14 ` Felician Nemeth
2024-04-06 6:09 ` Eli Zaretskii
2024-04-06 6:36 ` Eli Zaretskii [this message]
2024-04-06 14:33 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-06 15:07 ` Eli Zaretskii
2024-04-06 15:46 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-06 16:15 ` Eli Zaretskii
2024-04-06 20:00 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-04-07 5:28 ` Eli Zaretskii
2024-04-06 8:30 ` Sean Whitton
2024-04-06 17:32 ` Dmitry Gutov
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=86zfu73smn.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=70221@debbugs.gnu.org \
--cc=monnier@iro.umontreal.ca \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.