Fix dynamic binding wrapper in iter-lambda (bug#25965)
* lisp/emacs-lisp/generator.el (cps--make-dynamic-binding-wrapper): Remove extra evaluation of form. * test/lisp/emacs-lisp/generator-tests.el (cps-iter-lambda-with-dynamic-binding): New test.
This commit is contained in:
parent
2a32ee1fbc
commit
9a10c8713b
2 changed files with 11 additions and 2 deletions
|
@ -142,8 +142,7 @@ the CPS state machinery.
|
|||
`(let ((,dynamic-var ,static-var))
|
||||
(unwind-protect ; Update the static shadow after evaluation is done
|
||||
,form
|
||||
(setf ,static-var ,dynamic-var))
|
||||
,form)))
|
||||
(setf ,static-var ,dynamic-var)))))
|
||||
|
||||
(defmacro cps--with-dynamic-binding (dynamic-var static-var &rest body)
|
||||
"Evaluate BODY such that generated atomic evaluations run with
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue