diff options
author | Philipp Stephani <phst@google.com> | 2020-06-10 19:01:03 +0200 |
---|---|---|
committer | Philipp Stephani <phst@google.com> | 2020-06-14 20:01:28 +0200 |
commit | e96f78fca672c74b7bf1120b7683a50295418725 (patch) | |
tree | aded2f5b0e00ca786bbd70093fce422a229ecfd4 /test/lisp/emacs-lisp | |
parent | 62cf8f1649468fc2f6c4f8926ab5c4bb184bfbe8 (diff) | |
download | emacs-e96f78fca672c74b7bf1120b7683a50295418725.tar.gz emacs-e96f78fca672c74b7bf1120b7683a50295418725.tar.bz2 emacs-e96f78fca672c74b7bf1120b7683a50295418725.zip |
Band-aid for edebugging generator bodies (Bug#40434).
Edebug doesn't support them well. Rather than trying to fix Edebug,
disable instrumentation for now to prevent annoying bugs.
* lisp/emacs-lisp/generator.el (iter-defun, iter-lambda, iter-make)
(iter-do): Don't attempt to instrument bodies that are mangled by the
CPS transformer.
* test/lisp/emacs-lisp/generator-tests.el
(generator-tests-edebug): New regression test.
Diffstat (limited to 'test/lisp/emacs-lisp')
-rw-r--r-- | test/lisp/emacs-lisp/generator-tests.el | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/lisp/emacs-lisp/generator-tests.el b/test/lisp/emacs-lisp/generator-tests.el index bcfab201636..9b1a573ea6a 100644 --- a/test/lisp/emacs-lisp/generator-tests.el +++ b/test/lisp/emacs-lisp/generator-tests.el @@ -304,4 +304,13 @@ identical output." (1+ it))))))) -2))) +(ert-deftest generator-tests-edebug () + "Check that Bug#40434 is fixed." + (with-temp-buffer + (prin1 '(iter-defun generator-tests-edebug () + (iter-yield 123)) + (current-buffer)) + (edebug-defun)) + (should (eql (iter-next (generator-tests-edebug)) 123))) + ;;; generator-tests.el ends here |