X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Fclass.lisp;h=c3af80d3fceb023ca87b42b4ddf204a44066098b;hb=25fe91bf63fd473d9316675b0e0ca9be0079e9eb;hp=dcd40fee8d5f50810eb69b70e765e9a241e9bd1a;hpb=fb03344c5e8388e0b16512f1cb662d8cf5d13972;p=sbcl.git diff --git a/src/code/class.lisp b/src/code/class.lisp index dcd40fe..c3af80d 100644 --- a/src/code/class.lisp +++ b/src/code/class.lisp @@ -847,6 +847,11 @@ NIL is returned when no such class exists." (ensure-classoid-valid class1 layout1) (ensure-classoid-valid class2 layout2))) +(defun update-object-layout-or-invalid (object layout) + (if (typep (classoid-of object) 'standard-classoid) + (sb!pcl::check-wrapper-validity object) + (%layout-invalid-error object layout))) + ;;; Simple methods for TYPE= and SUBTYPEP should never be called when ;;; the two classes are equal, since there are EQ checks in those ;;; operations. @@ -939,12 +944,16 @@ NIL is returned when no such class exists." ;;;; PCL stuff -(def!struct (std-classoid (:include classoid) - (:constructor nil))) -(def!struct (standard-classoid (:include std-classoid) +;;; the CLASSOID that we use to represent type information for +;;; STANDARD-CLASS and FUNCALLABLE-STANDARD-CLASS. The type system +;;; side does not need to distinguish between STANDARD-CLASS and +;;; FUNCALLABLE-STANDARD-CLASS. +(def!struct (standard-classoid (:include classoid) (:constructor make-standard-classoid))) -(def!struct (random-pcl-classoid (:include std-classoid) - (:constructor make-random-pcl-classoid))) +;;; a metaclass for classes which aren't standardlike but will never +;;; change either. +(def!struct (static-classoid (:include classoid) + (:constructor make-static-classoid))) ;;;; built-in classes