From 9eec6e12fb6d22101631158dc1012276fd00facc Mon Sep 17 00:00:00 2001 From: Christophe Rhodes Date: Sun, 6 Nov 2005 19:21:06 +0000 Subject: [PATCH] 0.9.6.30: Propagate documentation from dslotds to eslotds as specified in ANSI 7.6.2. --- NEWS | 5 +++++ src/pcl/defs.lisp | 4 +++- src/pcl/std-class.lisp | 9 ++++++++- version.lisp-expr | 2 +- 4 files changed, 17 insertions(+), 3 deletions(-) diff --git a/NEWS b/NEWS index 41a3063..0e3aec8 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,11 @@ changes in sbcl-0.9.7 relative to sbcl-0.9.6: least permitted and maybe required by AMOP). As a consolation, however, the SBCL implementation of these functions now calls REINITIALIZE-INSTANCE as specified by AMOP. + * bug fix: slot-definition documentation is propagated as per ANSI + 7.6.2 to EFFECTIVE-SLOT-DEFINITIONS. + COMPUTE-EFFECTIVE-SLOT-DEFINITION now receives a :DOCUMENTATION + argument, as do eslotd initialization methods. (from Pascal + Costanza's "Closer" project) * bug fix: REINITIALIZE-INSTANCE on generic functions calls COMPUTE-DISCRIMINATING-FUNCTION (almost) unconditionally, as specified by AMOP. diff --git a/src/pcl/defs.lisp b/src/pcl/defs.lisp index 03ac566..d8ac2ec 100644 --- a/src/pcl/defs.lisp +++ b/src/pcl/defs.lisp @@ -467,7 +467,9 @@ :accessor slot-definition-type) (documentation :initform nil - :initarg :documentation) + :initarg :documentation + ;; FIXME: should we export this, as an extension? + :accessor %slot-definition-documentation) (class :initform nil :initarg :class diff --git a/src/pcl/std-class.lisp b/src/pcl/std-class.lisp index 255c316..915180e 100644 --- a/src/pcl/std-class.lisp +++ b/src/pcl/std-class.lisp @@ -1078,6 +1078,8 @@ (allocation nil) (allocation-class nil) (type t) + (documentation nil) + (documentationp nil) (namep nil) (initp nil) (allocp nil)) @@ -1092,6 +1094,10 @@ (setq initform (slot-definition-initform slotd) initfunction (slot-definition-initfunction slotd) initp t))) + (unless documentationp + (when (%slot-definition-documentation slotd) + (setq documentation (%slot-definition-documentation slotd) + documentationp t))) (unless allocp (setq allocation (slot-definition-allocation slotd) allocation-class (slot-definition-class slotd) @@ -1108,7 +1114,8 @@ :allocation allocation :allocation-class allocation-class :type type - :class class))) + :class class + :documentation documentation))) (defmethod compute-effective-slot-definition-initargs :around ((class structure-class) direct-slotds) diff --git a/version.lisp-expr b/version.lisp-expr index 0a9cdfa..905c7e6 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.9.6.29" +"0.9.6.30" -- 1.7.10.4