diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2023-03-01 12:31:09 -0500 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2023-03-01 12:31:09 -0500 |
commit | 1f1d36fa8080479083af8c69e8ea3756d51910fb (patch) | |
tree | 888d50f28fd910cd676e0d0f6f8a5f1f221cd5d3 /lisp/emacs-lisp | |
parent | 99df815c153265706edc839b7467fb3ae3b6e1b1 (diff) | |
download | emacs-1f1d36fa8080479083af8c69e8ea3756d51910fb.tar.gz emacs-1f1d36fa8080479083af8c69e8ea3756d51910fb.tar.bz2 emacs-1f1d36fa8080479083af8c69e8ea3756d51910fb.zip |
* lisp/emacs-lisp/debug-early.el (debug-early-backtrace): Fix bug#61847
The `noerror` arg of `require` doesn't do what Stefan naively thought
when he wrote this code, so use `condition-case` instead.
Also check for `cl-defmethod` since `cl-prin1` can't be loaded before
that anyway.
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r-- | lisp/emacs-lisp/debug-early.el | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lisp/emacs-lisp/debug-early.el b/lisp/emacs-lisp/debug-early.el index 395498f2206..e393daee879 100644 --- a/lisp/emacs-lisp/debug-early.el +++ b/lisp/emacs-lisp/debug-early.el @@ -46,10 +46,10 @@ of the build process." (print-escape-control-characters t) (print-escape-nonascii t) (prin1 (if (and (fboundp 'cl-prin1) - ;; If we're being called while - ;; bootstrapping, we won't be able to load - ;; cl-print. - (require 'cl-print nil t)) + (fboundp 'cl-defmethod) ;Used by `cl-print'. + (condition-case nil + (require 'cl-print) + (error nil))) #'cl-prin1 #'prin1))) (mapbacktrace |