From: Nikodemus Siivola Date: Tue, 28 Jul 2009 17:41:39 +0000 (+0000) Subject: 1.0.30.6: fix minor bug in DESCRIBE X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=c09f6c37a4b36901793d5a9ac7e99b5eeea83593;p=sbcl.git 1.0.30.6: fix minor bug in DESCRIBE * Generic functions defined by non-toplevel DEFMETHODs may have an :ASSUMED :WHERE-FROM in globaldb. --- diff --git a/NEWS b/NEWS index b111249..bc57154 100644 --- a/NEWS +++ b/NEWS @@ -17,6 +17,8 @@ changes relative to sbcl-1.0.30: * bug fix: minor violation of "otherwise inaccessible" rule for stack allocation could cause objects users might reasonably expect to be heap allocated to be stack allocated. + * bug fix: DESCRIBE signalled an error for generic functions under + certain circumstances. (reported by Leslie Polzer) changes in sbcl-1.0.30 relative to sbcl-1.0.29: * minor incompatible change: SB-THREAD:JOIN-THREAD-ERROR-THREAD and diff --git a/src/code/describe.lisp b/src/code/describe.lisp index b66fffd..468f4c0 100644 --- a/src/code/describe.lisp +++ b/src/code/describe.lisp @@ -527,7 +527,8 @@ (ecase (info :function :where-from name) (:declared "Declared") ;; This is hopefully clearer to users - ((:defined-method :defined) "Derived")))))) + ((:defined-method :defined) "Derived") + (:assumed)))))) (if (typep fun 'generic-function) (values fun "a generic function" @@ -553,7 +554,7 @@ (format stream "~%~A names ~A:" name what) (pprint-indent :block 2 stream)) (describe-lambda-list lambda-list stream) - (when ftype + (when (and ftype from) (format stream "~@:_~A type: ~S" from ftype)) (describe-documentation name 'function stream) (when (car inline) diff --git a/tests/interface.impure.lisp b/tests/interface.impure.lisp index 3be4ec4..6f697a5 100644 --- a/tests/interface.impure.lisp +++ b/tests/interface.impure.lisp @@ -241,5 +241,11 @@ #+sb-doc (with-test (:name (documentation built-in-function)) (assert (documentation 'cons 'function))) + +(with-test (:name :describe-generic-function-with-assumed-type) + ;; Signalled an error at one point + (flet ((zoo () (gogo))) + (defmethod gogo () nil) + (describe 'gogo))) ;;;; success diff --git a/version.lisp-expr b/version.lisp-expr index a7bca07..a54376b 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; 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".) -"1.0.30.5" +"1.0.30.6"