From: Nikodemus Siivola Date: Thu, 13 Mar 2008 15:23:32 +0000 (+0000) Subject: 1.0.15.28: SB-INTROSPECT: source-locations for objects X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=ad640ad16fb2ed5c8f080fbe6c66a45fa6bdbbe1;p=sbcl.git 1.0.15.28: SB-INTROSPECT: source-locations for objects * FIND-DEFINITION-SOURCE returns the source-location of the class for standard-objects, conditions, and structure objects. * Patch by Tobias C. Rittweiler. --- diff --git a/NEWS b/NEWS index a0ab05a..2a47167 100644 --- a/NEWS +++ b/NEWS @@ -4,6 +4,8 @@ changes in sbcl-1.0.16 relative to 1.0.15: NIL whenever we can't get a truename, as was the case before 1.0.14. * minor incompatible change: SB-BSD-SOCKETS:NAME-SERVICE-ERROR now inherits from ERROR instead of just CONDITION. + * new feature: SB-INTROSPECT can provide source locations for instances + as well. (thanks to Tobian Ritterweiler) * optimization: binding special variables now generates smaller code on threaded platforms. * optimization: MEMBER and ASSOC are over 50% faster for :TEST #'EQ diff --git a/contrib/sb-introspect/sb-introspect.lisp b/contrib/sb-introspect/sb-introspect.lisp index c9fed2f..5a36bf4 100644 --- a/contrib/sb-introspect/sb-introspect.lisp +++ b/contrib/sb-introspect/sb-introspect.lisp @@ -340,8 +340,10 @@ If an unsupported TYPE is requested, the function will return NIL. (struct-predicate-structure-class object))) (t (find-function-definition-source object)))) + ((or condition standard-object structure-object) + (find-definition-source (class-of object))) (t - (error "Don't know how to retrive source location for a ~S~%" + (error "Don't know how to retrieve source location for a ~S~%" (type-of object))))) (defun find-function-definition-source (function) diff --git a/version.lisp-expr b/version.lisp-expr index 20cbe20..2e5843e 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.15.27" +"1.0.15.28"