0.9.18.38:
authorJuho Snellman <jsnell@iki.fi>
Tue, 7 Nov 2006 10:22:09 +0000 (10:22 +0000)
committerJuho Snellman <jsnell@iki.fi>
Tue, 7 Nov 2006 10:22:09 +0000 (10:22 +0000)
commit4f8f4b25cb564509437d8fc26038143150077f14
tree146e4ba0f6354c493a1ac2216af6e7581c3b071a
parent6049dd2bf3dfe37080a30a4a751076c1254030bd
0.9.18.38:
        Typechecking for CLOS instance slots, based on the earlier
        clos-typechecking branch by Christophe Rhodes.

        To get the typechecking right, especially when considering
        inheritance where the slots in subclasses can have tighter
        :TYPEs than in the superclass, some major PCL optimizations
        need to be disabled. This slows down slot writes significantly.
        Typechecking is thus only enabled for safe code.

        * Store a function in each slot-definition with a non-T :TYPE, which
          checks whether its parameter is of the proper type for the slot.
        * Store in each class knowledge about whether the class was defined
          in an environment with (SAFETY 3) policy.
        * Don't do PV optimization for SETF of SLOT-VALUE in safe code.
        * When generating writer methods for classes defined in safe code,
          fetch the appropriate slotd for the instance and call its
          type-checking-function (if one exists) before doing the slot write.
        * Do the same in the slow path of SET-SLOT-VALUE
        * When generating a ctor for a MAKE-INSTANCE call in safe code,
          check the types of the supplied initargs.
        * Fix declaration handling for some binding forms in SB-WALK
        * Remove dead accessor-call optimization code
        * Tests
17 files changed:
NEWS
src/pcl/boot.lisp
src/pcl/braid.lisp
src/pcl/ctor.lisp
src/pcl/defclass.lisp
src/pcl/defs.lisp
src/pcl/dfun.lisp
src/pcl/fsc.lisp
src/pcl/slots-boot.lisp
src/pcl/slots.lisp
src/pcl/std-class.lisp
src/pcl/vector.lisp
src/pcl/walk.lisp
tests/clos-typechecking.impure.lisp [new file with mode: 0644]
tests/mop.impure-cload.lisp
tests/type.impure.lisp
version.lisp-expr