SB-KERNEL:%FUN-NAME on implicitly created generic functions

Bug #520695 reported by Tobias C. Rittweiler
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SBCL
Invalid
Medium
Unassigned

Bug Description

(defmethod method-without-defgeneric (x) x)

(with-test (:name :method-without-defgeneric+%fun-name)
  (assert (eq (sb-kernel:%fun-name #'method-without-defgeneric)
               'method-without-defgeneric)))

;;; Currently (1.0.35.x) %FUN-NAME returns
;;;
;;; (LAMBDA (&REST SB-PCL::ARGS))

Changed in sbcl:
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
Douglas Katzman (dougk) wrote :

First of all, this behavior has nothing to do with whether the GF was implicit or not.
* (defgeneric f (x))
#<STANDARD-GENERIC-FUNCTION F (0)>
* (sb-kernel:%fun-name #'f)
(LAMBDA (&REST SB-PCL::ARGS) :IN SB-PCL::MAKE-INITIAL-DFUN)

But the correct accessor is FUN-NAME, or more portably (nth-value 2 (function-lambda-expression x))

Changed in sbcl:
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.