chiark / gitweb /
src/method-aggregate.lisp: Allow useful behaviour if no primary methods.
[sod] / doc / list-exports.lisp
index 240ecc2f6a6fa6cfe5a3c0cd9f051159c5230b07..f58fb2b95c903918c42ab6dcd59d2a36ca75d78c 100755 (executable)
@@ -205,13 +205,17 @@ (defun pretty-symbol-name (symbol package)
                  (t (best-package-name pkg)))
            (or exportp (null pkg)) (symbol-name symbol))))
 
+(deftype interesting-class ()
+  '(or standard-class
+       structure-class
+       #.(class-name (class-of (find-class 'condition)))))
+
 (defun analyse-classes (package)
   (setf package (find-package package))
   (let ((classes (mapcan (lambda (symbol)
                           (let ((class (find-class symbol nil)))
                             (and class
-                                 (typep class '(or standard-class
-                                                structure-class))
+                                 (typep class 'interesting-class)
                                  (list class))))
                         (list-exported-symbols package)))
        (subs (make-hash-table)))
@@ -360,7 +364,7 @@ (defun analyse-generic-functions (package)
                                #'order-specializers
                                :key #'method-specializers))
            (when (gethash method methods)
-             (format t "~2T~{~A~^ ~}~%"
+             (format t "~2T~{~A~^ ~}~@[ [~{~(~S~)~^ ~}]~]~%"
                      (mapcar
                       (lambda (spec)
                         (etypecase spec
@@ -374,7 +378,8 @@ (defun analyse-generic-functions (package)
                                      (if (symbolp obj)
                                          (pretty-symbol-name obj package)
                                          obj))))))
-                      (method-specializers method))))))))))
+                      (method-specializers method))
+                     (method-qualifiers method)))))))))
 
 (defun check-slot-names (package)
   (setf package (find-package package))