From a01412f55c9345127db8e73471c80ccff5ece2b9 Mon Sep 17 00:00:00 2001 From: Nikodemus Siivola Date: Thu, 15 Dec 2005 22:08:38 +0000 Subject: [PATCH] 0.9.7.30: robustify sb-introspect when used with extended function names ...so that (find-definition-sources-by-name '(setf foo) :class) will return NIL instead of signaling an error. ...this makes it simpler to support M-. for SETF-names in Slime. --- contrib/sb-introspect/sb-introspect.lisp | 9 ++++++--- version.lisp-expr | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/contrib/sb-introspect/sb-introspect.lisp b/contrib/sb-introspect/sb-introspect.lisp index aa323a6..cd328d3 100644 --- a/contrib/sb-introspect/sb-introspect.lisp +++ b/contrib/sb-introspect/sb-introspect.lisp @@ -140,7 +140,10 @@ If an unsupported TYPE is requested, the function will return NIL. (flet ((listify (x) (if (listp x) x - (list x)))) + (list x))) + (get-class (name) + (and (symbolp name) + (find-class name nil)))) (listify (case type ((:variable) @@ -192,7 +195,7 @@ If an unsupported TYPE is requested, the function will return NIL. (symbol-function expander) expander))))) ((:structure) - (let ((class (find-class name nil))) + (let ((class (get-class name))) (if class (when (typep class 'sb-pcl::structure-class) (find-definition-source class)) @@ -200,7 +203,7 @@ If an unsupported TYPE is requested, the function will return NIL. (translate-source-location (sb-int:info :source-location :typed-structure name)))))) ((:condition :class) - (let ((class (find-class name nil))) + (let ((class (get-class name))) (when (and class (not (typep class 'sb-pcl::structure-class))) (when (eq (not (typep class 'sb-pcl::condition-class)) diff --git a/version.lisp-expr b/version.lisp-expr index 5099bba..9d11339 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".) -"0.9.7.29" +"0.9.7.30" -- 1.7.10.4