X-Git-Url: https://git.distorted.org.uk/~mdw/sod/blobdiff_plain/73eceea64f35d47eeecb808cb7bfecb6bac4299b..c6b4ed992d81518f240509e6ab212d8fe705485a:/src/class-finalize-proto.lisp diff --git a/src/class-finalize-proto.lisp b/src/class-finalize-proto.lisp index edd1bad..7a64ae3 100644 --- a/src/class-finalize-proto.lisp +++ b/src/class-finalize-proto.lisp @@ -92,6 +92,20 @@ If the chains are ill-formed (i.e., not distinct) then an error is signalled.")) +(export 'check-class-initializer) +(defgeneric check-class-initializer (slot class) + (:documentation + "Check that SLOT has an appropriate initializer. + + Signal an appropriate continuable error, possibly protected by + `finalization-error'. + + The initializer might come either from the SLOT's defining class (which it + already knows), or from the prospective instance CLASS, of which the + defining class will be (a superclass of) the metaclass. Or, if the slot + is magical, then the initial value might come from somewhere else and it + might be forbidden for a programmer to set it explicitly.")) + (export 'check-sod-class) (defgeneric check-sod-class (class) (:documentation