@item
the debugger is explicitly entered with the Lisp @code{break} or
-@code{debug} functions.
+@code{invoke-debugger} functions.
@end itemize
top-level. After printing its banner, the debugger prints the current
frame and the debugger prompt.
+When the debugger is invoked by a condition, ANSI mandates that the
+value of @code{*debugger-hook*}, if any, be called with two arguments:
+the condition that caused the debugger to be invoked and the previous
+value of @code{*debugger-hook*}. When this happens,
+@code{*debugger-hook*} is bound to NIL to prevent recursive
+errors. However, ANSI also mandates that @code{*debugger-hook*} not be
+invoked when the debugger is to be entered by the @code{break}
+function. For users who wish to provide an alternate debugger
+interface (and thus catch @code{break} entries into the debugger),
+SBCL provides @code{sb-ext:*invoke-debugger-hook*}, which is invoked
+during any entry into the debugger.
+
+@include var-sb-ext-star-invoke-debugger-hook-star.texinfo
+
@node The Debugger Command Loop
@comment node-name, next, previous, up
In the debugger, it is possible to override the printing behaviour of
the REPL.
-@defvr {Variable} *debug-print-variable-alist*
+@defvr {Variable} sb-debug:*debug-print-variable-alist*
An association list describing new bindings for special variables
(typically *PRINT-FOO* variables) to be used within the debugger, e.g.
remove the ambiguity in your code.~@:>"
accessor-name)
(setf (dd-predicate-name defstruct) nil))
- #-sb-xc-host
- (when (and (fboundp accessor-name)
- (not (accessor-inherited-data accessor-name defstruct)))
- (style-warn "redefining ~S in DEFSTRUCT" accessor-name)))
-
+ ;; FIXME: It would be good to check for name collisions here, but
+ ;; the easy check,
+ ;;x#-sb-xc-host
+ ;;x(when (and (fboundp accessor-name)
+ ;;x (not (accessor-inherited-data accessor-name defstruct)))
+ ;;x (style-warn "redefining ~S in DEFSTRUCT" accessor-name)))
+ ;; which was done until sbcl-0.8.11.18 or so, is wrong: it causes
+ ;; a warning at MACROEXPAND time, when instead the warning should
+ ;; occur not just because the code was constructed, but because it
+ ;; is actually compiled or loaded.
+ )
+
(when default-p
(setf (dsd-default slot) default))
(when type-p
(if read-only
(setf (dsd-read-only slot) t)
(when (dsd-read-only slot)
- (error "Slot ~S is :READ-ONLY in parent and must be :READ-ONLY in subtype ~S."
- name
+ (error "~@<The slot ~S is :READ-ONLY in superclass, and so must ~
+ be :READ-ONLY in subclass.~:@>"
(dsd-name slot)))))
slot))
(defmethod describe-object ((fun standard-generic-function) stream)
(format stream "~&~A is a generic function." fun)
(when (documentation fun t)
- (format stream "~& Function documentation: ~A" (documentation fun t)))
+ (format stream "~&Its documentation is: ~A" (documentation fun t)))
(format stream "~&Its lambda-list is:~& ~S"
(generic-function-pretty-arglist fun))
+ (format stream "~&Its method-combination is:~& ~S"
+ (generic-function-method-combination fun))
(let ((methods (generic-function-methods fun)))
(if (null methods)
(format stream "~&It has no methods.~%")
(assert (not (bug-332b-aux-p #(1 2 3 4 5 x 1 2 bug-332a-aux))))
(assert (bug-332b-aux-p #(1 2 3 4 5 x 1 2 bug-332b-aux)))
+;;; In sbcl-0.8.11.8 FBOUNDPness potential collisions of structure
+;;; slot accessors signalled a condition at macroexpansion time, not
+;;; when the code was actually compiled or loaded.
+(let ((defstruct-form '(defstruct bug-in-0-8-11-8 x)))
+ (defun bug-in-0-8-11-8-x (z) (print "some unrelated thing"))
+ (handler-case (macroexpand defstruct-form)
+ (warning (c)
+ (error "shouldn't warn just from macroexpansion here"))))
+
;;; success
(format t "~&/returning success~%")
(quit :unix-status 104)
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"0.8.11.18"
+"0.8.11.19"