all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Pip Cet <pipcet@protonmail.com>
Cc: martin rudalics <rudalics@gmx.at>,
	Lars Ingebrigtsen <larsi@gnus.org>,
	71774@debbugs.gnu.org
Subject: bug#71774: 31.0.50; Hash table weakness broken?
Date: Wed, 26 Jun 2024 09:23:27 -0400	[thread overview]
Message-ID: <jwvzfr7zvxw.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <cKBa-HkilR_7CpriVskQ_JfvtyPZ0t8cZRkllVeL-xAxZvsm3s-D_WvwrCoqtLEBTsXCoYywm2sB9MiS4FkGCRA7X8yn-Hyaf9wlohnXRpo=@protonmail.com> (Pip Cet's message of "Wed, 26 Jun 2024 09:12:45 +0000")

>> gets me nil too. So to make such tests work one has to tinker with
>> that obsolete variable 'values'. Worrisome.
> I believe that change, in commit 84f72f19e514db8f8f6e469340fb5fa0719d40b6,
> might have been unintentional. Stefan: is it intentional that the default
> behavior was changed to modify "values", even if
> eval-expression-debug-on-error is `t`?

No, indeed, it was an oversight.
The patch below should get us back to the previous behavior, tho I can't
see why we'd set `values` when `eval-expression-debug-on-error` is nil
and not when it's not.

Martin, can you confirm that it fixes the problem for you (so I can
install it on `emacs-30`)?

Apparently this was introduced by

    commit 4428c27c1ae7d5fe5233e8d7b001a8cd2fcdc56f
    Author: Lars Ingebrigtsen <larsi@gnus.org>
    Date:   Mon Feb 8 08:15:45 2021 +0100
    
        Record the value of `C-x C-e' in `values'
        
        * lisp/progmodes/elisp-mode.el (eval-last-sexp): Record the value
        in `values' (bug#22066) since we're messaging it.

I'd be in favor of just removing the call to `values--store-value` as
suggested by Matthias.


        Stefan


diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el
index 7d0312eb2a4..3423b9493f0 100644
--- a/lisp/progmodes/elisp-mode.el
+++ b/lisp/progmodes/elisp-mode.el
@@ -1633,7 +1633,8 @@ eval-last-sexp
 If `eval-expression-debug-on-error' is non-nil, which is the default,
 this command arranges for all errors to enter the debugger."
   (interactive "P")
-  (values--store-value
+  (funcall
+   (if eval-expression-debug-on-error #'values--store-value #'identity)
    (handler-bind ((error (if eval-expression-debug-on-error
                              #'eval-expression--debug #'ignore)))
      (elisp--eval-last-sexp eval-last-sexp-arg-internal))))






  reply	other threads:[~2024-06-26 13:23 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-25 13:57 bug#71774: 31.0.50; Hash table weakness broken? martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-25 15:02 ` Eli Zaretskii
2024-06-25 17:19   ` Mattias Engdegård
2024-06-26  8:38     ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-26  9:39       ` Mattias Engdegård
2024-06-25 15:25 ` Pip Cet via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-26  8:37   ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-26  8:46     ` Pip Cet via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-26  9:08       ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-26  9:12         ` Pip Cet via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-26 13:23           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2024-06-26 13:53             ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-26 14:11               ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-27  7:19                 ` martin rudalics via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-27 18:42                   ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-27 23:42                     ` Stefan Kangas
2024-06-28 12:59                       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-28  5:29                     ` Eli Zaretskii
2024-06-26 14:13             ` Pip Cet via Bug reports for GNU Emacs, the Swiss army knife of text editors

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=jwvzfr7zvxw.fsf-monnier+emacs@gnu.org \
    --to=bug-gnu-emacs@gnu.org \
    --cc=71774@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=pipcet@protonmail.com \
    --cc=rudalics@gmx.at \
    /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.