X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Fcompiler.pure.lisp;h=7dcc183567ab236799eb9e0a76fdfc621714807e;hb=5cf3c4259d529e180d75d4d140f344e600d2b06b;hp=381bb2f6ae8a3e91b194b6a7be47ae80195ccb5f;hpb=f5522c7149744e4faf34313b18d0d3588d2a9d98;p=sbcl.git diff --git a/tests/compiler.pure.lisp b/tests/compiler.pure.lisp index 381bb2f..7dcc183 100644 --- a/tests/compiler.pure.lisp +++ b/tests/compiler.pure.lisp @@ -2675,3 +2675,18 @@ (compile nil '(lambda (x) (declare (type (and simple-string (satisfies array-has-fill-pointer-p)) x)) (array-element-type x)))) + +(with-test (:name :rest-list-type-derivation) + (multiple-value-bind (type derivedp) + (funcall (compile nil `(lambda (&rest args) + (sb-c::compiler-derived-type args))) + nil) + (assert (eq 'list type)) + (assert derivedp))) + +(with-test (:name :base-char-typep-elimination) + (assert (eq (funcall (lambda (ch) + (declare (type base-char ch) (optimize (speed 3) (safety 0))) + (typep ch 'base-char)) + t) + t)))