aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Kastrup2007-04-17 23:24:13 +0000
committerDavid Kastrup2007-04-17 23:24:13 +0000
commitfc6a22502ee9c109ee0664a35822bf188500181d (patch)
treee29e56a557caaa2938fe60895c79a01478662f84
parentf7510c4036f4bd752b564a8d51db7854b52fe4ae (diff)
downloademacs-fc6a22502ee9c109ee0664a35822bf188500181d.tar.gz
emacs-fc6a22502ee9c109ee0664a35822bf188500181d.zip
* NEWS: Mention `query-replace-regexp-eval' being deprecated.
* replace.el (query-replace-regexp-eval): Deprecate.
-rw-r--r--etc/ChangeLog4
-rw-r--r--etc/NEWS12
-rw-r--r--lisp/ChangeLog4
-rw-r--r--lisp/replace.el10
4 files changed, 24 insertions, 6 deletions
diff --git a/etc/ChangeLog b/etc/ChangeLog
index 1f2b33fe8a8..9003f73da96 100644
--- a/etc/ChangeLog
+++ b/etc/ChangeLog
@@ -1,3 +1,7 @@
12007-04-17 David Kastrup <dak@gnu.org>
2
3 * NEWS: Mention `query-replace-regexp-eval' being deprecated.
4
12007-04-15 Glenn Morris <rgm@gnu.org> 52007-04-15 Glenn Morris <rgm@gnu.org>
2 6
3 * FTP: Make it a duplicate of ../FTP. 7 * FTP: Make it a duplicate of ../FTP.
diff --git a/etc/NEWS b/etc/NEWS
index 9e18d887834..be01229237e 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -633,12 +633,12 @@ a match if part of it has a read-only property.
633*** When used interactively, the commands `query-replace-regexp' and 633*** When used interactively, the commands `query-replace-regexp' and
634`replace-regexp' allow \,expr to be used in a replacement string, 634`replace-regexp' allow \,expr to be used in a replacement string,
635where expr is an arbitrary Lisp expression evaluated at replacement 635where expr is an arbitrary Lisp expression evaluated at replacement
636time. In many cases, this will be more convenient than using 636time. `\#' in a replacement string now refers to the count of
637`query-replace-regexp-eval'. `\#' in a replacement string now refers 637replacements already made by the replacement command. All regular
638to the count of replacements already made by the replacement command. 638expression replacement commands now allow `\?' in the replacement
639All regular expression replacement commands now allow `\?' in the 639string to specify a position where the replacement string can be
640replacement string to specify a position where the replacement string 640edited for each replacement. `query-replace-regexp-eval' is now
641can be edited for each replacement. 641deprecated since it offers no additional functionality.
642 642
643+++ 643+++
644*** query-replace uses isearch lazy highlighting when the new user option 644*** query-replace uses isearch lazy highlighting when the new user option
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 44ae91ba0aa..ffc605eaedc 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,7 @@
12007-04-17 David Kastrup <dak@gnu.org>
2
3 * replace.el (query-replace-regexp-eval): Deprecate.
4
12007-04-17 Alan Mackenzie <acm@muc.de> 52007-04-17 Alan Mackenzie <acm@muc.de>
2 6
3 * progmodes/cc-cmds.el (c-beginning-of-defun): With -ve arg and 7 * progmodes/cc-cmds.el (c-beginning-of-defun): With -ve arg and
diff --git a/lisp/replace.el b/lisp/replace.el
index a8dfd043c72..ed1fa9a6b59 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -303,6 +303,11 @@ Use \\[repeat-complex-command] after this command for details."
303 303
304(defun query-replace-regexp-eval (regexp to-expr &optional delimited start end) 304(defun query-replace-regexp-eval (regexp to-expr &optional delimited start end)
305 "Replace some things after point matching REGEXP with the result of TO-EXPR. 305 "Replace some things after point matching REGEXP with the result of TO-EXPR.
306
307Interactive use of this function is deprecated in favor of the
308`\\,' feature of `query-replace-regexp'. For non-interactive use, a loop
309using `search-forward-regexp' and `replace-match' is preferred.
310
306As each match is found, the user must type a character saying 311As each match is found, the user must type a character saying
307what to do with it. For directions, type \\[help-command] at that time. 312what to do with it. For directions, type \\[help-command] at that time.
308 313
@@ -354,6 +359,11 @@ Fourth and fifth arg START and END specify the region to operate on."
354 (perform-replace regexp (cons 'replace-eval-replacement to-expr) 359 (perform-replace regexp (cons 'replace-eval-replacement to-expr)
355 t 'literal delimited nil nil start end)) 360 t 'literal delimited nil nil start end))
356 361
362(make-obsolete 'query-replace-regexp-eval
363 "for interactive use, use the special `\\,' feature of
364`query-replace-regexp' instead. Non-interactively, a loop
365using `search-forward-regexp' and `replace-match' is preferred." "22.1")
366
357(defun map-query-replace-regexp (regexp to-strings &optional n start end) 367(defun map-query-replace-regexp (regexp to-strings &optional n start end)
358 "Replace some matches for REGEXP with various strings, in rotation. 368 "Replace some matches for REGEXP with various strings, in rotation.
359The second argument TO-STRINGS contains the replacement strings, 369The second argument TO-STRINGS contains the replacement strings,