categorizing the kinds of definitions that SYMBOL has."
(let ((things nil))
- (when (boundp symbol)
+ (when (or (boundp symbol) (documentation symbol 'variable))
(push (if (constantp symbol) :constant :variable) things))
- (when (fboundp symbol)
+ (when (or (fboundp symbol) (documentation symbol 'function))
(push (cond ((macro-function symbol) :macro)
((typep (fdefinition symbol) 'generic-function)
:generic)
(generic-function (push :setf-generic things))
(function (push :setf-function things))
(null)))
- (when (find-class symbol nil)
- (push :class things))
+ (when (or (find-class symbol nil) (documentation symbol 'type))
+ (push (if (find-class symbol nil) :class :type) things))
(when (specialized-on-p #'sod:expand-c-type-spec 0 symbol)
(push :c-type-spec things))
(when (specialized-on-p #'sod:expand-c-type-form 0 symbol)