diff options
author | Lars Ingebrigtsen <larsi@gnus.org> | 2022-02-22 14:43:35 +0100 |
---|---|---|
committer | Lars Ingebrigtsen <larsi@gnus.org> | 2022-02-22 14:43:35 +0100 |
commit | c6465d65faf0808b2bc7226ca108322c19d75b41 (patch) | |
tree | 8c0bb2f408824d17b5cc1ed1ad14d2403068e5d3 /lisp/emacs-lisp | |
parent | 85567d57981448200ba2617e45d5d4d3e5721cf7 (diff) | |
download | emacs-c6465d65faf0808b2bc7226ca108322c19d75b41.tar.gz emacs-c6465d65faf0808b2bc7226ca108322c19d75b41.tar.bz2 emacs-c6465d65faf0808b2bc7226ca108322c19d75b41.zip |
Don't signal an error on re-builder startup with rx syntax
* lisp/emacs-lisp/re-builder.el (reb-initialize-buffer): Make
startup with rx syntax not signal an error (bug#54107).
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r-- | lisp/emacs-lisp/re-builder.el | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/re-builder.el b/lisp/emacs-lisp/re-builder.el index 38726ca048e..24770fac67f 100644 --- a/lisp/emacs-lisp/re-builder.el +++ b/lisp/emacs-lisp/re-builder.el @@ -323,7 +323,10 @@ Except for Lisp syntax this is the same as `reb-regexp'.") (reb-lisp-mode)) (t (reb-mode))) (reb-restart-font-lock) - (reb-do-update)) + ;; When using `rx' syntax, the initial syntax () is invalid. But + ;; don't signal an error in that case. + (ignore-errors + (reb-do-update))) (defun reb-mode-buffer-p () "Return non-nil if the current buffer is a RE Builder buffer." |