1.0.7.1: dynamic extent value cells
[sbcl.git] / src / compiler / ir2tran.lisp
index db050bc..ebc963c 100644 (file)
   (emit-move-template node block (type-check-template type) value result)
   (values))
 
-;;; Allocate an indirect value cell. Maybe do some clever stack
-;;; allocation someday.
+;;; Allocate an indirect value cell.
 (defevent make-value-cell-event "Allocate heap value cell for lexical var.")
 (defun emit-make-value-cell (node block value res)
   (event make-value-cell-event node)
-  (vop make-value-cell node block value res))
+  (let ((leaf (tn-leaf res)))
+    (vop make-value-cell node block value (and leaf (leaf-dynamic-extent leaf))
+         res)))
 \f
 ;;;; leaf reference