[Ecls-list] Bug: Incorrect closure over call-next-method in 12.2.1

Pascal Costanza pc at p-cos.net
Sat Feb 25 20:02:36 UTC 2012


Hi,

Consider the following test case:

(defclass c () ())
(defclass d (c) ())

(defgeneric test (obj))

(defmethod test ((obj c)) 42)

(defmethod test ((obj d))
  (flet ((do-it ()
           (let ((next-value (call-next-method)))
             next-value)))
    (lambda () (do-it))))


> (test (make-instance 'd))

#<bytecompiled-closure #<bytecompiled-function 000000010db4d280>>
> (funcall *)

Condition of type: SIMPLE-ERROR
No next method.

Available restarts:

1. (RESTART-TOPLEVEL) Go back to Top-Level REPL.


Similar code worked before in 11.1.1. (Instead of the error, the last funcall should return 42.)


Best,
Pascal

--
Pascal Costanza







More information about the ecl-devel mailing list