Skip to content

Commit 936d92d

Browse files
committed
Always stash maximum vsp value before makeclosure
1 parent 6d64076 commit 936d92d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

lisp/comp/trans.l

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -679,9 +679,12 @@
679679
(inc pushcount))
680680
(:closure (lab env0 env1)
681681
(if env1
682-
(send self :store "w") ; store to w before increasing the pushcount
683-
(send self :clearpush)) ; clear other pending values
684-
(send self :reset-vsp)
682+
(progn
683+
(send self :reset-vsp) ; use the push-count before decrease
684+
(send self :store "w")) ; store to w before increasing the pushcount
685+
(progn
686+
(send self :clearpush) ; clear other pending values
687+
(send self :reset-vsp))) ; use the push-count after increase
685688
(send self :push
686689
(format nil "makeclosure(codevec,quotevec,~A,~A,~A)"
687690
lab (if env0 "env" "NIL") (if env1 "w" "NIL"))))

0 commit comments

Comments
 (0)