X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Fcold-error.lisp;h=96a5670a437c402b867dead80d0d98d05d4fddcf;hb=13fb19c3183a0effb7c35a2d453d6c6c91726e26;hp=429516038c2571b6029279e54912ef916204ff84;hpb=4898ef32c639b1c7f4ee13a5ba566ce6debd03e6;p=sbcl.git diff --git a/src/code/cold-error.lisp b/src/code/cold-error.lisp index 4295160..96a5670 100644 --- a/src/code/cold-error.lisp +++ b/src/code/cold-error.lisp @@ -27,10 +27,16 @@ 'simple-condition 'signal)) (*handler-clusters* *handler-clusters*) - (old-bos *break-on-signals*)) + (old-bos *break-on-signals*) + (bos-actually-breaking nil)) (restart-case - (when (typep condition *break-on-signals*) - (let ((*break-on-signals* nil)) + (let ((break-on-signals *break-on-signals*) + (*break-on-signals* nil)) + ;; The rebinding encloses the TYPEP so that a bogus + ;; type specifier will not lead to infinite recursion when + ;; TYPEP fails. + (when (typep condition break-on-signals) + (setf bos-actually-breaking t) (break "~A~%BREAK was entered because of *BREAK-ON-SIGNALS* ~ (now rebound to NIL)." condition))) @@ -45,7 +51,13 @@ ;; unless we provide this restart.) (reassign (new-value) :report - "Return from BREAK and assign a new value to *BREAK-ON-SIGNALS*." + (lambda (stream) + (format stream + (if bos-actually-breaking + "Return from BREAK and assign a new value to ~ + *BREAK-ON-SIGNALS*." + "Assign a new value to *BREAK-ON-SIGNALS* and ~ + continue with signal handling."))) :interactive (lambda () (let (new-value)