X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Fcross-type.lisp;h=72d50923e9ab887aea612fe9b8115eb4885acd01;hb=c712f88b26cd7547ee984b90e18c134401335bc3;hp=32becc381e97bce8778ca7d53a9900fbe23517f2;hpb=7f9f1fd113d7047731bda9dab2c7719cdf092a21;p=sbcl.git diff --git a/src/code/cross-type.lisp b/src/code/cross-type.lisp index 32becc3..72d5092 100644 --- a/src/code/cross-type.lisp +++ b/src/code/cross-type.lisp @@ -108,7 +108,7 @@ ;;; T unless it's certain) and the second value to tell whether it's ;;; certain. (defun cross-typep (host-object raw-target-type) - (let ((target-type (type-expand raw-target-type))) + (let ((target-type (typexpand raw-target-type))) (flet ((warn-and-give-up () ;; We don't have to keep track of this as long as system ;; performance is acceptable, since giving up @@ -248,7 +248,7 @@ (if (stringp host-object) (warn-and-give-up) (values nil t))) - ((target-type-is-in '(character base-char)) + ((target-type-is-in '(character base-char standard-char)) (cond ((typep host-object 'standard-char) (values t t)) ((not (characterp host-object)) @@ -289,6 +289,12 @@ ;; trivial. (and (every/type #'cross-typep host-object rest)) (or (any/type #'cross-typep host-object rest)) + (not + (multiple-value-bind (value surep) + (cross-typep host-object (car rest)) + (if surep + (values (not value) t) + (warn-and-give-up)))) ;; If we want to work with the KEYWORD type, we need ;; to grok (SATISFIES KEYWORDP). (satisfies