]> git.eshelyaron.com Git - emacs.git/commitdiff
(with-current-buffer): Rename buffer argument to buffer-or-name.
authorMartin Rudalics <rudalics@gmx.at>
Sat, 25 Oct 2008 09:18:19 +0000 (09:18 +0000)
committerMartin Rudalics <rudalics@gmx.at>
Sat, 25 Oct 2008 09:18:19 +0000 (09:18 +0000)
lisp/ChangeLog
lisp/subr.el

index 56d04af23e784ebfddc0f204e7fdbf05fa35f675..b6651bd3ac09a5ad7585581896f6269e4cb24475 100644 (file)
@@ -1,5 +1,7 @@
 2008-10-25  Martin Rudalics  <rudalics@gmx.at>
 
+       * subr.el (with-current-buffer): Rename buffer argument to
+       buffer-or-name.
        * window.el (get-buffer-window-list): Rename buffer argument to
        buffer-or-name and make it optional.
 
index 5a1f4d42ee2d913d5f0da388e9143a4959e38067..0dda4b0e604a4d4eef09083eb977e1d34022df24 100644 (file)
@@ -2483,14 +2483,14 @@ Similar to `call-process-shell-command', but calls `process-file'."
 \f
 ;;;; Lisp macros to do various things temporarily.
 
-(defmacro with-current-buffer (buffer &rest body)
-  "Execute the forms in BODY with BUFFER temporarily current.
-BUFFER can be a buffer or a buffer name.
-The value returned is the value of the last form in BODY.
-See also `with-temp-buffer'."
+(defmacro with-current-buffer (buffer-or-name &rest body)
+  "Execute the forms in BODY with BUFFER-OR-NAME temporarily current.
+BUFFER-OR-NAME must be a buffer or the name of an existing buffer.
+The value returned is the value of the last form in BODY.  See
+also `with-temp-buffer'."
   (declare (indent 1) (debug t))
   `(save-current-buffer
-     (set-buffer ,buffer)
+     (set-buffer ,buffer-or-name)
      ,@body))
 
 (defmacro with-selected-window (window &rest body)