emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master 6171d5b: * lisp/replace.el (perform-replace): Docum


From: Stefan Monnier
Subject: [Emacs-diffs] master 6171d5b: * lisp/replace.el (perform-replace): Document `replacements'.
Date: Tue, 11 Aug 2015 15:43:15 +0000

branch: master
commit 6171d5b1f9edb09ca43c219f08e7a372de8740b2
Author: Stefan Monnier <address@hidden>
Commit: Stefan Monnier <address@hidden>

    * lisp/replace.el (perform-replace): Document `replacements'.
    
    (perform-replace): Move the description of the format of `replacements' from
    the body's comment to the docstring.
---
 lisp/replace.el |   13 +++++++------
 1 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/lisp/replace.el b/lisp/replace.el
index a541c55..aa1da08 100644
--- a/lisp/replace.el
+++ b/lisp/replace.el
@@ -2080,7 +2080,13 @@ see the documentation of `replace-match' to find out how 
to simulate
 `case-replace'.
 
 This function returns nil if and only if there were no matches to
-make, or the user didn't cancel the call."
+make, or the user didn't cancel the call.
+
+REPLACEMENTS is either a string, a list of strings, or a cons cell
+containing a function and its first argument.  The function is
+called to generate each replacement like this:
+  (funcall (car replacements) (cdr replacements) replace-count)
+It must return a string."
   (or map (setq map query-replace-map))
   (and query-flag minibuffer-auto-raise
        (raise-frame (window-frame (minibuffer-window))))
@@ -2136,11 +2142,6 @@ make, or the user didn't cancel the call."
     (when (eq (lookup-key map (vector last-input-event)) 'automatic-all)
       (setq query-flag nil multi-buffer t))
 
-    ;; REPLACEMENTS is either a string, a list of strings, or a cons cell
-    ;; containing a function and its first argument.  The function is
-    ;; called to generate each replacement like this:
-    ;;   (funcall (car replacements) (cdr replacements) replace-count)
-    ;; It must return a string.
     (cond
      ((stringp replacements)
       (setq next-replacement replacements



reply via email to

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