Update of /cvsroot/sbcl/sbcl/src/pcl
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv15036/src/pcl
Modified Files:
methods.lisp
Log Message:
1.0.17.33: fix PRINT-OBJECT cache
We mustn't compute the cached cache too early, otherwise we'll
cache effective methods before the actual methods (on RESTART
and the two storage-condition classes) are defined.
Index: methods.lisp
===================================================================
RCS file: /cvsroot/sbcl/sbcl/src/pcl/methods.lisp,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -d -r1.81 -r1.82
--- methods.lisp 9 Jun 2008 21:49:15 -0000 1.81
+++ methods.lisp 11 Jun 2008 20:04:23 -0000 1.82
@@ -1567,11 +1567,19 @@
(cond ((/= nkeys 1)
;; KLUDGE: someone has defined a method
;; specialized on the second argument: punt.
+ (setf po-cache nil)
(make-initial-dfun gf))
(po-cache
(multiple-value-bind (dfun cache info)
(make-caching-dfun gf po-cache)
(set-dfun gf dfun cache info)))
+ ;; the relevant PRINT-OBJECT methods get defined
+ ;; late, by delayed DEF!METHOD. We mustn't cache
+ ;; the effective method for our classes earlier
+ ;; than the relevant PRINT-OBJECT methods are
+ ;; defined...
+ ((boundp 'sb-impl::*delayed-def!method-args*)
+ (make-initial-dfun gf))
(t (multiple-value-bind (dfun cache info)
(make-final-dfun-internal
gf
|