changeset 21294:e010f1191668

(perform-replace): Before recursive edit, get the match data as markers, and set real-match-data.
author Richard M. Stallman <rms@gnu.org>
date Thu, 26 Mar 1998 06:31:26 +0000
parents 21de06ed5f74
children f399e51d6d11
files lisp/replace.el
diffstat 1 files changed, 5 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/replace.el	Thu Mar 26 04:28:37 1998 +0000
+++ b/lisp/replace.el	Thu Mar 26 06:31:26 1998 +0000
@@ -846,9 +846,11 @@
 		      ((eq def 'recenter)
 		       (recenter nil))
 		      ((eq def 'edit)
-		       (set-match-data
-			(prog1 (match-data)
-			  (save-excursion (recursive-edit))))
+		       (goto-char (match-beginning 0))
+		       (funcall search-function search-string limit t)
+		       (setq real-match-data (match-data))
+		       (save-excursion (recursive-edit))
+		       (set-match-data real-match-data)
 		       ;; Before we make the replacement,
 		       ;; decide whether the search string
 		       ;; can match again just after this match.