changeset 5308:f14639c69ed3

(vip-replace-string): Don't use replace-regexp.
author Richard M. Stallman <rms@gnu.org>
date Thu, 23 Dec 1993 04:53:48 +0000
parents 069c54e77fd1
children dc1a3f9ea36d
files lisp/emulation/vip.el
diffstat 1 files changed, 7 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emulation/vip.el	Thu Dec 23 04:52:56 1993 +0000
+++ b/lisp/emulation/vip.el	Thu Dec 23 04:53:48 1993 +0000
@@ -926,9 +926,13 @@
 			   (if vip-re-replace "regexp replace"
 			     "string replace"))))
       (if vip-re-replace
-	  (replace-regexp
-	   str
-	   (vip-read-string (format "Replace regexp \"%s\" with: " str)))
+	  ;; (replace-regexp
+	  ;;  str
+	  ;;  (vip-read-string (format "Replace regexp \"%s\" with: " str)))
+	  (while (re-search-forward str nil t)
+	    (replace-match (vip-read-string
+			    (format "Replace regexp \"%s\" with: " str))
+			   nil nil))
 	(replace-string
 	 str
 	 (vip-read-string (format "Replace \"%s\" with: " str)))))))