GNU bug report logs - #34765
26.1; with-temp-buffer should not run buffer-list-update-hook

Previous Next

Package: emacs;

Reported by: Alexander Miller <alexanderm <at> web.de>

Date: Tue, 5 Mar 2019 22:58:02 UTC

Severity: normal

Tags: fixed

Found in version 26.1

Fixed in version 28.1

Done: "Basil L. Contovounesios" <contovob <at> tcd.ie>

Bug is archived. No further changes may be made.

Full log


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

From: "Basil L. Contovounesios" <contovob <at> tcd.ie>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 34765 <at> debbugs.gnu.org, rudalics <at> gmx.at, larsi <at> gnus.org,
 monnier <at> IRO.UMontreal.CA, alexanderm <at> web.de
Subject: Re: bug#34765: 26.1; with-temp-buffer should not run
 buffer-list-update-hook
Date: Mon, 07 Dec 2020 22:16:23 +0000
[Message part 1 (text/plain, inline)]
"Basil L. Contovounesios" <contovob <at> tcd.ie> writes:

> I'll finish up Martin's patch with some docs then.

How's the attached?  The gist of it is that get-buffer-create and
generate-new-buffer gain a new argument for inhibiting buffer hooks,
which is set in with-temp-buffer, with-temp-file, with-output-to-string,
insert-file-contents, Vprin1_to_string_buffer, and code_conversion_save.

Arising questions:

0. Why isn't kill-buffer-hook defined as a DEFVAR_LISP?
   Is it because it has to be defined in init_buffer_once?
   If so, why is that the case?

1. Is it okay for with-temp-buffer, with-temp-file, and
   with-output-to-string to unconditionally inhibit buffer hooks,
   or should this be controlled by e.g. a global variable?

Thanks,

-- 
Basil

[0001-Inhibit-buffer-hooks-in-temporary-buffers.patch (text/x-diff, attachment)]

This bug report was last modified 4 years and 153 days ago.

Previous Next


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