GNU bug report logs -
#44943
28.0.50; defvar may return INITVALUE and overwrite symbol's value
Previous Next
Reported by: Kazuhiro Ito <kzhr <at> d1.dion.ne.jp>
Date: Sun, 29 Nov 2020 10:50:02 UTC
Severity: normal
Tags: moreinfo
Found in version 28.0.50
Done: Kazuhiro Ito <kzhr <at> d1.dion.ne.jp>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 44943 in the body.
You can then email your comments to 44943 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44943
; Package
emacs
.
(Sun, 29 Nov 2020 10:50:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Kazuhiro Ito <kzhr <at> d1.dion.ne.jp>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Sun, 29 Nov 2020 10:50:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
When evaluate below codes, I get unexpected result.
(defvar test 1)
-> test
It is expected.
(defvar test 2)
-> 2
It should return 'test'.
(symbol-value 'test)
-> 2
It should return 1.
--
Kazuhiro Ito
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44943
; Package
emacs
.
(Sun, 29 Nov 2020 11:02:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 44943 <at> debbugs.gnu.org (full text, mbox):
Kazuhiro Ito <kzhr <at> d1.dion.ne.jp> writes:
> When evaluate below codes, I get unexpected result.
>
> (defvar test 1)
>
> -> test
>
> It is expected.
>
> (defvar test 2)
>
> -> 2
>
> It should return 'test'.
>
> (symbol-value 'test)
>
> -> 2
>
> It should return 1.
When you say "evaluate", what do you mean? Doing `C-x C-e' after the
form? If it's the latter, then the doc string explains what's
happening (and this is new behaviour in Emacs 28):
----
C-x C-e runs the command eval-last-sexp (found in global-map), which
is an interactive compiled Lisp function in ‘elisp-mode.el’.
It is bound to C-x C-e.
(eval-last-sexp EVAL-LAST-SEXP-ARG-INTERNAL)
Probably introduced at or before Emacs version 24.4.
Evaluate sexp before point; print value in the echo area.
Interactively, with a non ‘-’ prefix argument, print output into
current buffer.
This commands handles ‘defvar’, ‘defcustom’ and ‘defface’ the
same way that ‘eval-defun’ does. See the doc string of that
function for details.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Added tag(s) moreinfo.
Request was from
Lars Ingebrigtsen <larsi <at> gnus.org>
to
control <at> debbugs.gnu.org
.
(Sun, 29 Nov 2020 11:02:02 GMT)
Full text and
rfc822 format available.
Reply sent
to
Kazuhiro Ito <kzhr <at> d1.dion.ne.jp>
:
You have taken responsibility.
(Sun, 29 Nov 2020 12:07:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Kazuhiro Ito <kzhr <at> d1.dion.ne.jp>
:
bug acknowledged by developer.
(Sun, 29 Nov 2020 12:07:01 GMT)
Full text and
rfc822 format available.
Message #15 received at 44943-done <at> debbugs.gnu.org (full text, mbox):
> > When evaluate below codes, I get unexpected result.
> >
> > (defvar test 1)
> >
> > -> test
> >
> > It is expected.
> >
> > (defvar test 2)
> >
> > -> 2
> >
> > It should return 'test'.
> >
> > (symbol-value 'test)
> >
> > -> 2
> >
> > It should return 1.
>
> When you say "evaluate", what do you mean? Doing `C-x C-e' after the
> form? If it's the latter, then the doc string explains what's
> happening (and this is new behaviour in Emacs 28):
I meant C-j in *scratch* buffer (eval-print-last-sexp) and `C-x C-e'.
They return the same result. I didn't notice the change of
eval-last-sexp, sorry. I'm closing this issue.
--
Kazuhiro Ito
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sun, 27 Dec 2020 12:24:07 GMT)
Full text and
rfc822 format available.
This bug report was last modified 4 years and 258 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.