X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Ftypep.lisp;h=5c7ee7bb89ce249e1461b59a7f803a539e5b7fe6;hb=a74b0bdb483504f6faddf8089f848f61ed94b92a;hp=19ac49a3c8881095b069f15ecd0933e766b872f9;hpb=4eb1a6d3ad2b7dcc19ac0ec979a1eb1eb049659a;p=sbcl.git diff --git a/src/code/typep.lisp b/src/code/typep.lisp index 19ac49a..5c7ee7b 100644 --- a/src/code/typep.lisp +++ b/src/code/typep.lisp @@ -13,9 +13,10 @@ ;;; test that the host Lisp object OBJECT translates to a target SBCL ;;; type TYPE. This behavior is needed e.g. to test for the validity ;;; of numeric subtype bounds read when cross-compiling.) -(defun typep (object type) +(defun typep (object type &optional environment) #!+sb-doc "Is OBJECT of type TYPE?" + (declare (ignore environment)) ;; Actually interpreting types at runtime is done by %TYPEP. The ;; cost of the extra function call here should be negligible ;; compared to the cost of interpreting types. (And the compiler @@ -196,7 +197,7 @@ (declare (optimize speed)) (when (layout-invalid obj-layout) (if (and (typep (sb!xc:class-of object) 'sb!xc:standard-class) object) - (setq obj-layout (pcl-check-wrapper-validity-hook object)) + (setq obj-layout (sb!pcl::check-wrapper-validity object)) (error "TYPEP was called on an obsolete object (was class ~S)." (class-proper-name (layout-class obj-layout))))) (let ((layout (class-layout class)) @@ -208,8 +209,7 @@ (when (eq (svref obj-inherits i) layout) (return t)))))) -;;; to be redefined as PCL::CHECK-WRAPPER-VALIDITY when PCL is loaded -;;; -;;; FIXME: should probably be renamed SB!PCL:CHECK-WRAPPER-VALIDITY -(defun pcl-check-wrapper-validity-hook (object) +;;; This implementation is a placeholder to use until PCL is set up, +;;; at which time it will be overwritten by a real implementation. +(defun sb!pcl::check-wrapper-validity (object) object)