From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Helmut Eller <eller.helmut@gmail.com>
Cc: 18154@debbugs.gnu.org
Subject: bug#18154: 24.4.50; eval-buffer ignores debug-on-error sometimes
Date: Wed, 06 Aug 2014 13:11:51 -0400 [thread overview]
Message-ID: <jwv8un1mtqt.fsf-monnier+emacsbugs@gnu.org> (raw)
In-Reply-To: <m2r412zhw4.fsf@gmail.com> (Helmut Eller's message of "Wed, 30 Jul 2014 22:55:07 +0200")
> Starting Emacs with:
> emacs -Q -nw \
> -eval '(setq debug-on-error t)' \
> -eval '(insert "(defun f () (push))")' \
> -f eval-buffer
> only prints this message:
> Eager macro-expansion failure: (wrong-number-of-arguments (2 . 2) 0)
> This is not what I expect; Emacs should enter the debugger instead.
The eager-macroexpansion is not indispensable (so far), so any errors
that happen during it are demoted to mere warnings (like the line you
quote above). Hence debug-on-error doesn't cause you to get
a backtrace. You'd need to use debug-on-signal for that.
But you should indeed be dropped into the debugger if/when you call `f'
(unless you redefine `push' to accept 0 arguments before you call `f',
obviously).
> If "(defun f () (push))" is replaced by "(/ 1 0)" then the
> debugger pops up as expected.
Of course. Note that when (defun f () (push)) is evaluated, it just
defines `f' but doesn't actually run `push' (tho eager-macroexpansion
tries to macroexpand `push' in the hope to avoid having to do it
every time `f' gets called).
Stefan
next prev parent reply other threads:[~2014-08-06 17:11 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-30 20:55 bug#18154: 24.4.50; eval-buffer ignores debug-on-error sometimes Helmut Eller
2014-08-06 17:11 ` Stefan Monnier [this message]
2014-08-07 6:44 ` Helmut Eller
2014-08-07 12:29 ` Stefan Monnier
2021-08-19 15:56 ` Lars Ingebrigtsen
2022-06-29 15:12 ` Stefan Kangas
2022-06-30 9:13 ` Lars Ingebrigtsen
2022-06-30 10:54 ` Eli Zaretskii
2022-06-30 11:18 ` 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=jwv8un1mtqt.fsf-monnier+emacsbugs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=18154@debbugs.gnu.org \
--cc=eller.helmut@gmail.com \
/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.