mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-27 07:37:33 +00:00
(perform-replace): Check for empty stack.
This commit is contained in:
parent
dd24e6a699
commit
237e6ab056
@ -514,12 +514,16 @@ which will run faster and probably do exactly what you want."
|
||||
(setq keep-going nil)
|
||||
(setq done t))
|
||||
((eq def 'backup)
|
||||
(let ((elt (car stack)))
|
||||
(goto-char (car elt))
|
||||
(setq replaced (eq t (cdr elt)))
|
||||
(or replaced
|
||||
(store-match-data (cdr elt)))
|
||||
(setq stack (cdr stack))))
|
||||
(if stack
|
||||
(let ((elt (car stack)))
|
||||
(goto-char (car elt))
|
||||
(setq replaced (eq t (cdr elt)))
|
||||
(or replaced
|
||||
(store-match-data (cdr elt)))
|
||||
(setq stack (cdr stack)))
|
||||
(message "No previous match")
|
||||
(ding 'no-terminate)
|
||||
(sit-for 1)))
|
||||
((eq def 'act)
|
||||
(or replaced
|
||||
(replace-match next-replacement nocasify literal))
|
||||
|
Loading…
Reference in New Issue
Block a user