mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 18:40:39 -08:00
Move batch backtrace code to top_level_2
Move ad-hoc code meant to ease debugging of bootstrap (and batch mode) to `top_level_2` so it doesn't pollute `signal_or_quit`. * src/lisp.h (pop_handler, push_handler_bind): Declare. * src/keyboard.c (top_level_2): Setup an error handler to call `debug-early` when noninteractive. * src/eval.c (pop_handler): Not static any more. (signal_or_quit): Remove special case for noninteractive use. (push_handler_bind): New function, extracted from `Fhandler_bind_1`. (Fhandler_bind_1): Use it. (syms_of_eval): Declare `Qdebug_early__handler`. * lisp/emacs-lisp/debug-early.el (debug-early-backtrace): Weed out frames below `debug-early`. (debug-early--handler): New function.
This commit is contained in:
parent
80b081a0ac
commit
604e34338f
4 changed files with 31 additions and 25 deletions
|
|
@ -94,4 +94,8 @@ available before `debug' was usable.)"
|
|||
(prin1 (cdr (car (cdr args)))) ; The error data.
|
||||
(debug-early-backtrace)))
|
||||
|
||||
(defalias 'debug-early--handler ;Called from C.
|
||||
#'(lambda (err)
|
||||
(if backtrace-on-error-noninteractive (debug-early 'error err))))
|
||||
|
||||
;;; debug-early.el ends here.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue