Changeset 14254


Ignore:
Timestamp:
11/26/12 19:38:28 (8 years ago)
Author:
rschlatte
Message:

Fix (documentation symbol 'function) when symbol names a generic function

Location:
trunk/abcl/src/org/armedbear/lisp
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/abcl/src/org/armedbear/lisp/Primitives.java

    r14215 r14254  
    56715671            if (doc == NIL) {
    56725672                if (docType == Symbol.FUNCTION && object instanceof Symbol) {
     5673                    // Generic functions are handled at lisp-level, not here
    56735674                    LispObject function = object.getSymbolFunction();
    56745675                    if (function != null)
     
    56935694
    56945695        {
     5696            // Generic functions are handled at lisp-level, not here
    56955697            object.setDocumentation(docType, documentation);
    56965698            return documentation;
  • trunk/abcl/src/org/armedbear/lisp/clos.lisp

    r14164 r14254  
    33413341
    33423342(defmethod documentation ((x symbol) (doc-type (eql 'function)))
    3343   (%documentation x 'function))
     3343  (if (typep (fdefinition x) 'generic-function)
     3344      (documentation (fdefinition x) doc-type)
     3345      (%documentation x doc-type)))
     3346
     3347(defmethod (setf documentation) (new-value (x symbol) (doc-type (eql 'function)))
     3348  (if (typep (fdefinition x) 'generic-function)
     3349      (setf (documentation (fdefinition x) 'function) new-value)
     3350      (%set-documentation x 'function new-value)))
    33443351
    33453352(defmethod documentation ((x symbol) (doc-type (eql 'type)))
Note: See TracChangeset for help on using the changeset viewer.