From: Michael Heerdegen <michael_heerdegen@web.de>
To: 40975@debbugs.gnu.org
Subject: bug#40975: 28.0.50; Variable gets buffer-local unexpectedly
Date: Thu, 30 Apr 2020 04:26:16 +0200 [thread overview]
Message-ID: <87368lso8n.fsf@web.de> (raw)
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.
Maybe there is a problem in this case because the `setq' setting is in
the same lexical scope as the `make-local-variable' call?
TIA,
Michael.
In GNU Emacs 28.0.50 (build 57, x86_64-pc-linux-gnu, GTK+ Version 3.24.18, cairo version 1.16.0)
of 2020-04-29 built on drachen
Repository revision: fe9be663833db1bf99f38c981378255f88ff5d06
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12008000
System Description: Debian GNU/Linux bullseye/sid
next reply other threads:[~2020-04-30 2:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-30 2:26 Michael Heerdegen [this message]
2020-10-22 14:27 ` bug#40975: 28.0.50; Variable gets buffer-local unexpectedly Lars Ingebrigtsen
2020-10-23 18:07 ` Michael Heerdegen
2020-10-24 19:53 ` Lars Ingebrigtsen
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=87368lso8n.fsf@web.de \
--to=michael_heerdegen@web.de \
--cc=40975@debbugs.gnu.org \
/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.