Skip to content

Commit d7356aa

Browse files
committed
Reset flet cbindframe after progn
1 parent 936d92d commit d7356aa

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

lisp/comp/comp.l

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1295,16 +1295,15 @@
12951295
;; reset cbindframes to force re-evaluation
12961296
;; this is needed to ensure that each closure has an
12971297
;; unique and compatible mapping
1298-
(dolist (fdef flets-tmp)
1299-
(when (fdef . cbindframe)
1300-
(setq (fdef . cbindframe) t)))
1298+
(send self :reset-flets-cbindframe flets-tmp)
13011299

13021300
;; evaluate body
13031301
(setq flets (append flets-tmp flets))
13041302
(if recursive-scope (send-all newcomps :change-flets flets))
13051303
(send self :progn bodies)
13061304
(if (not recursive-scope) (send newcomp :change-flets flets))
13071305
;; unwind/restore
1306+
(send self :reset-flets-cbindframe flets-tmp)
13081307
(setq flets (nthcdr (length flets-tmp) flets))
13091308
(send self :delete-frame 'flet nil)
13101309
(send trans :del-frame (fletframe . specials) (fletframe . locals))))
@@ -1316,6 +1315,10 @@
13161315
(send self :progn bodies)
13171316
(setq flets (nthcdr (length funcs) flets)))
13181317
(:change-flets (newflets) (setq flets newflets))
1318+
(:reset-flets-cbindframe (flets-tmp)
1319+
(dolist (fdef flets-tmp)
1320+
(when (fdef . cbindframe)
1321+
(setq (fdef . cbindframe) t))))
13191322
(:declare (args)
13201323
;; bind statements and return type declared variables
13211324
(let (v acc)

0 commit comments

Comments
 (0)