diff options
author | Juri Linkov <juri@linkov.net> | 2023-03-22 09:44:02 +0200 |
---|---|---|
committer | Juri Linkov <juri@linkov.net> | 2023-03-22 09:44:02 +0200 |
commit | 84963956535e9eff38b0d7638ce751039eb44bc2 (patch) | |
tree | eb4caa68fcbea8cc27fe11fe62ad8f071856e28e /lisp/outline.el | |
parent | 3d3bbaace692384a895ec55ff7e5a91ad66463bb (diff) | |
download | emacs-84963956535e9eff38b0d7638ce751039eb44bc2.tar.gz emacs-84963956535e9eff38b0d7638ce751039eb44bc2.tar.bz2 emacs-84963956535e9eff38b0d7638ce751039eb44bc2.zip |
* lisp/outline.el (outline--fix-buttons-after-change): Add save-match-data.
It's important for a hook in after-change-functions not to change match-data.
Otherwise it breaks functions that make changes in the buffer, such as
for example, successive calls to delete-region in smerge-keep-n, etc.
Diffstat (limited to 'lisp/outline.el')
-rw-r--r-- | lisp/outline.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/outline.el b/lisp/outline.el index a89985d1990..0e90c59c285 100644 --- a/lisp/outline.el +++ b/lisp/outline.el @@ -1877,7 +1877,7 @@ With a prefix argument, show headings up to that LEVEL." (save-excursion (goto-char beg) (setq beg (pos-bol))) (save-excursion (goto-char end) (setq end (pos-eol))) (remove-overlays beg end 'outline-button t) - (outline--fix-up-all-buttons beg end)) + (save-match-data (outline--fix-up-all-buttons beg end))) (defvar-keymap outline-navigation-repeat-map |