]> git.eshelyaron.com Git - emacs.git/commit
Edebug: Disable backtracking when hitting a &define keyword.
authorPhilipp Stephani <phst@google.com>
Thu, 18 Mar 2021 11:40:08 +0000 (12:40 +0100)
committerPhilipp Stephani <phst@google.com>
Sat, 10 Apr 2021 16:19:49 +0000 (18:19 +0200)
commit53dfd85a7f971875e716a55f010ee508bce89eed
tree3eb0b220ff838287f4d6cd3cd45d19794aceecf7
parentb72571ca49dd16be174f02ed14b460c136c9aaf2
Edebug: Disable backtracking when hitting a &define keyword.

Edebug doesn't deal well with backtracking out of definitions, see
Bug#41988.  Rather than trying to support this rare situation (e.g. by
implementing a multipass parser), prevent it by adding an implicit
gate.

* lisp/emacs-lisp/edebug.el (edebug--match-&-spec-op): Disable
backtracking when hitting a &define keyword.

* test/lisp/emacs-lisp/edebug-tests.el
(edebug-tests-duplicate-&define): New unit test.
(edebug-tests--duplicate-&define): New helper macro.

* doc/lispref/edebug.texi (Backtracking): Mention &define in the list
of constructs that disable backtracking.

* etc/NEWS: Document new behavior.
doc/lispref/edebug.texi
etc/NEWS
lisp/emacs-lisp/edebug.el
test/lisp/emacs-lisp/edebug-tests.el