X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fmain.lisp;h=c3afdc717d064dcfb0dbf3e57d5f4721865bb1fc;hb=fdf46e7bd7aba9b5c8af629fdb2692d9b33b9207;hp=6ed7cb3e6969ffbca3e48524f7b1e14918bd9003;hpb=3fc4b561752c5ad4519b882a3b9bdfe7a8207532;p=sbcl.git diff --git a/src/compiler/main.lisp b/src/compiler/main.lisp index 6ed7cb3..c3afdc7 100644 --- a/src/compiler/main.lisp +++ b/src/compiler/main.lisp @@ -115,6 +115,8 @@ (defvar *compile-object* nil) (declaim (type object *compile-object*)) + +(defvar *fopcompile-label-counter*) ;;;; WITH-COMPILATION-UNIT and WITH-COMPILATION-VALUES @@ -852,16 +854,19 @@ ;;; *TOPLEVEL-LAMBDAS* instead. (defun convert-and-maybe-compile (form path) (declare (list path)) - (let* ((*top-level-form-noted* (note-top-level-form form t)) - (*lexenv* (make-lexenv - :policy *policy* - :handled-conditions *handled-conditions* - :disabled-package-locks *disabled-package-locks*)) - (tll (ir1-toplevel form path nil))) - (if (eq *block-compile* t) - (push tll *toplevel-lambdas*) - (compile-toplevel (list tll) nil)) - nil)) + (if (fopcompilable-p form) + (let ((*fopcompile-label-counter* 0)) + (fopcompile form path nil)) + (let* ((*top-level-form-noted* (note-top-level-form form t)) + (*lexenv* (make-lexenv + :policy *policy* + :handled-conditions *handled-conditions* + :disabled-package-locks *disabled-package-locks*)) + (tll (ir1-toplevel form path nil))) + (if (eq *block-compile* t) + (push tll *toplevel-lambdas*) + (compile-toplevel (list tll) nil)) + nil))) ;;; Macroexpand FORM in the current environment with an error handler. ;;; We only expand one level, so that we retain all the intervening