sbcl.sbcl/tests/block-compile-test-4.lisp
Charles Zhang c45ff731fc block compilation: Add START-BLOCK and END-BLOCK declarations.
And respect ANSI with the proclamation processing at that. (The CMU CL
code did some magic proclaim handling instead which was the initial
reason the support got gutted in the first place, as far as I can
tell.)
2020-04-30 22:27:54 -07:00

19 lines
257 B
Common Lisp

;;; From the CMU CL user manual.
(declaim (sb-ext:start-block fun1 fun3))
(defun fun1 (x)
(print x))
(defun fun2 ()
(1+ (fun1 6)))
(defun fun3 (x)
(if x
(fun1 3)
(fun2)))
(declaim (sb-ext:end-block))
(defun fun4 (z)
(+ 2 (fun1 z)))