changeset 6410:3989978f6631

(perform-replace): Set match-data markers to nil before discarding them.
author Roland McGrath <roland@gnu.org>
date Fri, 18 Mar 1994 12:16:08 +0000
parents 2f1e5e14dc25
children aea7be7b925c
files lisp/replace.el
diffstat 1 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/replace.el	Fri Mar 18 11:54:24 1994 +0000
+++ b/lisp/replace.el	Fri Mar 18 12:16:08 1994 +0000
@@ -1,6 +1,6 @@
 ;;; replace.el --- replace commands for Emacs.
 
-;; Copyright (C) 1985, 1986, 1987, 1992 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1986, 1987, 1992, 1994 Free Software Foundation, Inc.
 
 ;; This file is part of GNU Emacs.
 
@@ -573,10 +573,10 @@
 	      (setq stack
 		    (cons (cons (point)
 				(or replaced
-				    (mapcar
-				     (function (lambda (elt)
-						 (and elt
-						      (marker-position elt))))
+				    (mapcar (lambda (elt)
+					      (and elt
+						   (prog1 (marker-position elt)
+						     (set-marker elt nil))))
 				     (match-data))))
 			  stack))
 	      (if replaced (setq replace-count (1+ replace-count)))))