From d71896ded395b8453794f0c2e121af1cd095de8b Mon Sep 17 00:00:00 2001 From: Nikodemus Siivola Date: Mon, 17 May 2004 21:21:36 +0000 Subject: [PATCH] 0.8.10.33: Fixed ansi-test MAKE-INSTANCES-OBSOLETE.2: ... MAKE-INSTANCES-OBSOLETE returns the class name, not the class object when called with a symbol. ... Regression test for the same. --- NEWS | 2 ++ src/pcl/std-class.lisp | 4 +++- tests/clos.impure.lisp | 7 +++++++ version.lisp-expr | 2 +- 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 29710b5..3d8db4e 100644 --- a/NEWS +++ b/NEWS @@ -2445,6 +2445,8 @@ changes in sbcl-0.8.11 relative to sbcl-0.8.10: :LOAD-TOPLEVEL context; this appears to decrease fasl sizes by approximately 10%. * fixed some bugs revealed by Paul Dietz' test suite: + ** MAKE-INSTANCES-OBSOLETE returns the class name when called with + a symbol. ** Fixed an optimization bug related to inheritance of initforms from local to shared slots. ** FILE-POSITION works as specified on BROADCAST-STREAMs. diff --git a/src/pcl/std-class.lisp b/src/pcl/std-class.lisp index a6cec9d..ca020b4 100644 --- a/src/pcl/std-class.lisp +++ b/src/pcl/std-class.lisp @@ -1328,7 +1328,9 @@ class))) (defmethod make-instances-obsolete ((class symbol)) - (make-instances-obsolete (find-class class))) + (make-instances-obsolete (find-class class)) + ;; ANSI wants the class name when called with a symbol. + class) ;;; OBSOLETE-INSTANCE-TRAP is the internal trap that is called when we ;;; see an obsolete instance. The times when it is called are: diff --git a/tests/clos.impure.lisp b/tests/clos.impure.lisp index d8d5946..7ef3e46 100644 --- a/tests/clos.impure.lisp +++ b/tests/clos.impure.lisp @@ -777,5 +777,12 @@ ((magic :initarg :size :initform 2))) (assert (= 1 (slot-value i 'magic)))) +;;; MAKE-INSTANCES-OBSOLETE return values +(defclass one-more-to-obsolete () ()) +(assert (eq 'one-more-to-obsolete + (make-instances-obsolete 'one-more-to-obsolete))) +(assert (eq (find-class 'one-more-to-obsolete) + (make-instances-obsolete (find-class 'one-more-to-obsolete)))) + ;;;; success (sb-ext:quit :unix-status 104) diff --git a/version.lisp-expr b/version.lisp-expr index 3b39ef3..8a4f4ae 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; checkins which aren't released. (And occasionally for internal ;;; versions, especially for internal versions off the main CVS ;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".) -"0.8.10.32" +"0.8.10.33" -- 1.7.10.4