emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master e25d6cb 1/4: Use fileloop directly in vc-dir to avo


From: Lars Ingebrigtsen
Subject: [Emacs-diffs] master e25d6cb 1/4: Use fileloop directly in vc-dir to avoid obsolete function
Date: Sun, 16 Jun 2019 09:21:27 -0400 (EDT)

branch: master
commit e25d6cb0381c641e61bcf69e420a41186df06299
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>

    Use fileloop directly in vc-dir to avoid obsolete function
    
    * lisp/vc/vc-dir.el (vc-dir-query-replace-regexp): Rewrite to use
    fileloop directly to avoid the obsolete function
    tags-query-replace.
---
 lisp/vc/vc-dir.el | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/lisp/vc/vc-dir.el b/lisp/vc/vc-dir.el
index 6afc599..7af1e0d 100644
--- a/lisp/vc/vc-dir.el
+++ b/lisp/vc/vc-dir.el
@@ -45,6 +45,8 @@
 ;;; Code:
 (eval-when-compile (require 'cl-lib))
 
+(declare-function fileloop-continue "fileloop")
+
 (defcustom vc-dir-mode-hook nil
   "Normal hook run by `vc-dir-mode'.
 See `run-hooks'."
@@ -823,8 +825,11 @@ with the command \\[tags-loop-continue]."
       (if (and buffer (with-current-buffer buffer
                        buffer-read-only))
          (error "File `%s' is visited read-only" file))))
-  (tags-query-replace from to delimited
-                     '(mapcar 'car (vc-dir-marked-only-files-and-states))))
+  (fileloop-initialize-replace
+   from to (mapcar 'car (vc-dir-marked-only-files-and-states))
+   (if (equal from (downcase from)) nil 'default)
+   delimited)
+  (fileloop-continue))
 
 (defun vc-dir-ignore ()
   "Ignore the current file."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]