GNU bug report logs - #40975
28.0.50; Variable gets buffer-local unexpectedly

Previous Next

Package: emacs;

Reported by: Michael Heerdegen <michael_heerdegen <at> web.de>

Date: Thu, 30 Apr 2020 02:27:01 UTC

Severity: normal

Found in version 28.0.50

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Michael Heerdegen <michael_heerdegen <at> web.de>
Cc: 40975 <at> debbugs.gnu.org
Subject: bug#40975: 28.0.50; Variable gets buffer-local unexpectedly
Date: Thu, 22 Oct 2020 16:27:42 +0200
Michael Heerdegen <michael_heerdegen <at> web.de> writes:

> Hello,
>
> here is a reproducer:
>
> #+begin_src emacs-lisp
> (defun test ()
>   (make-local-variable 'my-test-var)
>   (with-current-buffer (get-buffer-create "Testbuffer")
>     (setq my-test-var 27)))
> #+end_src
>
> If you eval M-: (test) e.g. in emacs -Q and inspect the binding of
> `my-test-var' in "Testbuffer" and the other buffers, you'll see that the
> variable has become buffer local in "Testbuffer" though it has never
> been made local there.  This is the bug.

I'm seeing the opposite -- my-test-var is local to whatever buffer I
said M-: (test) in (but is unbound there), and is bound and has the
value 27 in all other buffers.

Which is what I'd expect?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




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

Previous Next


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