X-Git-Url: http://christophe.rhodes.io/gitweb/?p=specializable.git;a=blobdiff_plain;f=specializable.lisp;h=979f51476cb01d41b4709c77409b458955bdd0df;hp=29ad9260ff1f2d78abc78879e0e50902013081dc;hb=0e588c71c0bbb390d0ff8a6227df896fad4bb025;hpb=0ffa1258a3f10cf28cbe1751ef92431aa54521c0 diff --git a/specializable.lisp b/specializable.lisp index 29ad926..979f514 100644 --- a/specializable.lisp +++ b/specializable.lisp @@ -112,7 +112,7 @@ ;;; FIXME: in some kind of order, the discriminating function needs to handle: ;;; - argument count checking; ;;; - keyword argument validity; -;;; - flushing the emf cache on method addition/removal +;;; - DONE flushing the emf cache on method addition/removal ;;; - flushing the cache on class redefinition; ;;; - cache thread-safety. (defmethod sb-mop:compute-discriminating-function ((gf specializable-generic-function)) @@ -124,6 +124,9 @@ (sb-pcl::invoke-emf emfun args) (slow-method-lookup gf args generalizers))))) +(defmethod reinitialize-instance :after ((gf specializable-generic-function) &key) + (clrhash (emf-table gf))) + (defun slow-method-lookup (gf args generalizers) ;; differs from closette (multiple-value-bind (applicable-methods definitivep)