X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fpcl%2Fearly-low.lisp;h=cbe9c779a08ede1b7a10c8ef03013e3d5c3c94e4;hb=79f4c3de36b3c7d0d41497e2543d3ed6a135cb46;hp=cfad90f782a44990aa9c4ad9dcb2eb7d759081db;hpb=ff92598854bf7cae8d57fe49cef4d9a98e1ab345;p=sbcl.git diff --git a/src/pcl/early-low.lisp b/src/pcl/early-low.lisp index cfad90f..cbe9c77 100644 --- a/src/pcl/early-low.lisp +++ b/src/pcl/early-low.lisp @@ -42,7 +42,13 @@ ;;; #-SB-FLUID (FIND-PACKAGE NAME) ;;; #+SB-FLUID `(FIND-PACKAGE ,NAME)) ;;; and use that to replace all three variables.) -(defvar *pcl-package* (find-package "SB-PCL")) +(defvar *pcl-package* (find-package "SB-PCL")) + +(declaim (inline defstruct-classoid-p)) +(defun defstruct-classoid-p (classoid) + ;; It is non-obvious to me why STRUCTURE-CLASSOID-P doesn't + ;; work instead of this. -- NS 2008-03-14 + (typep (layout-info (classoid-layout classoid)) 'defstruct-description)) ;;; This excludes structure types created with the :TYPE option to ;;; DEFSTRUCT. It also doesn't try to deal with types created by @@ -53,12 +59,10 @@ ;;; it needs a more mnemonic name. -- WHN 19991204 (defun structure-type-p (type) (and (symbolp type) - (not (condition-type-p type)) (let ((classoid (find-classoid type nil))) - (and classoid - (typep (layout-info - (classoid-layout classoid)) - 'defstruct-description))))) + (and classoid + (not (condition-classoid-p classoid)) + (defstruct-classoid-p classoid))))) ;;; Symbol contruction utilities (defun format-symbol (package format-string &rest format-arguments) @@ -76,48 +80,52 @@ (condition-classoid-p (find-classoid type nil)))) (declaim (special *the-class-t* - *the-class-vector* *the-class-symbol* - *the-class-string* *the-class-sequence* - *the-class-rational* *the-class-ratio* - *the-class-number* *the-class-null* *the-class-list* - *the-class-integer* *the-class-float* *the-class-cons* - *the-class-complex* *the-class-character* - *the-class-bit-vector* *the-class-array* - *the-class-stream* + *the-class-vector* *the-class-symbol* + *the-class-string* *the-class-sequence* + *the-class-rational* *the-class-ratio* + *the-class-number* *the-class-null* *the-class-list* + *the-class-integer* *the-class-float* *the-class-cons* + *the-class-complex* *the-class-character* + *the-class-bit-vector* *the-class-array* + *the-class-stream* *the-class-file-stream* + *the-class-string-stream* - *the-class-slot-object* - *the-class-structure-object* - *the-class-std-object* - *the-class-standard-object* - *the-class-funcallable-standard-object* - *the-class-class* - *the-class-generic-function* - *the-class-built-in-class* - *the-class-slot-class* - *the-class-condition-class* - *the-class-structure-class* - *the-class-std-class* - *the-class-standard-class* - *the-class-funcallable-standard-class* - *the-class-method* - *the-class-standard-method* - *the-class-standard-reader-method* - *the-class-standard-writer-method* - *the-class-standard-boundp-method* - *the-class-standard-generic-function* - *the-class-standard-effective-slot-definition* + *the-class-slot-object* + *the-class-structure-object* + *the-class-standard-object* + *the-class-funcallable-standard-object* + *the-class-class* + *the-class-generic-function* + *the-class-built-in-class* + *the-class-slot-class* + *the-class-condition-class* + *the-class-structure-class* + *the-class-std-class* + *the-class-standard-class* + *the-class-funcallable-standard-class* + *the-class-forward-referenced-class* + *the-class-method* + *the-class-standard-method* + *the-class-standard-reader-method* + *the-class-standard-writer-method* + *the-class-standard-boundp-method* + *the-class-global-reader-method* + *the-class-global-writer-method* + *the-class-global-boundp-method* + *the-class-standard-generic-function* + *the-class-standard-effective-slot-definition* - *the-eslotd-standard-class-slots* - *the-eslotd-funcallable-standard-class-slots*)) + *the-eslotd-standard-class-slots* + *the-eslotd-funcallable-standard-class-slots*)) (declaim (special *the-wrapper-of-t* - *the-wrapper-of-vector* *the-wrapper-of-symbol* - *the-wrapper-of-string* *the-wrapper-of-sequence* - *the-wrapper-of-rational* *the-wrapper-of-ratio* - *the-wrapper-of-number* *the-wrapper-of-null* - *the-wrapper-of-list* *the-wrapper-of-integer* - *the-wrapper-of-float* *the-wrapper-of-cons* - *the-wrapper-of-complex* *the-wrapper-of-character* - *the-wrapper-of-bit-vector* *the-wrapper-of-array*)) + *the-wrapper-of-vector* *the-wrapper-of-symbol* + *the-wrapper-of-string* *the-wrapper-of-sequence* + *the-wrapper-of-rational* *the-wrapper-of-ratio* + *the-wrapper-of-number* *the-wrapper-of-null* + *the-wrapper-of-list* *the-wrapper-of-integer* + *the-wrapper-of-float* *the-wrapper-of-cons* + *the-wrapper-of-complex* *the-wrapper-of-character* + *the-wrapper-of-bit-vector* *the-wrapper-of-array*)) (/show "finished with early-low.lisp")