X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Fcompiler.pure.lisp;h=d047047c7bcc62af59436fc66545d7b36a672d87;hb=a5f57fb517f9ce87e0a602c5d496a132a4527f5e;hp=3430814a8ac47bc3dbdb408750447a50255d4508;hpb=3352e447d32d6786a5609cd53c6b3f2be7ab3e08;p=sbcl.git diff --git a/tests/compiler.pure.lisp b/tests/compiler.pure.lisp index 3430814..d047047 100644 --- a/tests/compiler.pure.lisp +++ b/tests/compiler.pure.lisp @@ -4285,7 +4285,15 @@ (with-test (:name :escape-analysis-for-nlxs) (flet ((test (check lambda &rest args) - (let ((fun (compile nil lambda))) + (let* ((cell-note nil) + (fun (handler-bind ((compiler-note + (lambda (note) + (when (search + "Allocating a value-cell at runtime for" + (princ-to-string note)) + (setf cell-note t))))) + (compile nil lambda)))) + (assert (eql check cell-note)) (if check (assert (eq :ok @@ -4299,17 +4307,20 @@ :ok))))) (ctu:assert-no-consing (apply fun args)))))) (test nil `(lambda (x) + (declare (optimize speed)) (block out (flet ((ex () (return-from out 'out!))) (typecase x (cons (or (car x) (ex))) (t (ex)))))) :foo) (test t `(lambda (x) + (declare (optimize speed)) (funcall (block nasty (flet ((oops () (return-from nasty t))) #'oops)))) t) (test t `(lambda (r) + (declare (optimize speed)) (block out (flet ((ex () (return-from out r))) (lambda (x) @@ -4317,6 +4328,7 @@ (cons (or (car x) (ex))) (t (ex))))))) t t) (test t `(lambda (x) + (declare (optimize speed)) (flet ((eh (x) (flet ((meh () (return-from eh 'meh))) (lambda ()