X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Fcompiler.impure.lisp;h=6b01a474db4c1e3425f6beb6e8c16c8cad50fda8;hb=ce798749f957d005670b71edf38b893264e4f7ba;hp=ae57aa9f4bac209aa103488ce0a8cd27da56b7ed;hpb=23c0c48f562d7dc5d1615bf13cb831b46c91d106;p=sbcl.git diff --git a/tests/compiler.impure.lisp b/tests/compiler.impure.lisp index ae57aa9..6b01a47 100644 --- a/tests/compiler.impure.lisp +++ b/tests/compiler.impure.lisp @@ -15,6 +15,9 @@ ;;;; absolutely no warranty. See the COPYING and CREDITS files for ;;;; more information. +(when (eq sb-ext:*evaluator-mode* :interpret) + (sb-ext:quit :unix-status 104)) + (load "test-util.lisp") (load "assertoid.lisp") (use-package "TEST-UTIL") @@ -1388,4 +1391,29 @@ (storage-condition (e) (error e))) +;;; warnings due to step-insturmentation +(defclass debug-test-class () ()) +(handler-case + (compile nil '(lambda () + (declare (optimize (debug 3))) + (defmethod print-object ((x debug-test-class) s) + (call-next-method)))) + ((and (not style-warning) warning) (e) + (error e))) + +;;; program-error from bad lambda-list keyword +(assert (eq :ok + (handler-case + (funcall (lambda (&whole x) + (list &whole x))) + (program-error () + :ok)))) +(assert (eq :ok + (handler-case + (let ((*evaluator-mode* :interpret)) + (funcall (eval '(lambda (&whole x) + (list &whole x))))) + (program-error () + :ok)))) + ;;; success