emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] trunk r116601: * lisp/saveplace.el (toggle-save-place): Fi


From: Glenn Morris
Subject: [Emacs-diffs] trunk r116601: * lisp/saveplace.el (toggle-save-place): Fix argument handling (tiny change)
Date: Fri, 28 Feb 2014 06:45:07 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 116601
revision-id: address@hidden
parent: address@hidden
fixes bug: http://debbugs.gnu.org/16673
author: Andy Sawyer <address@hidden>
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Thu 2014-02-27 22:44:49 -0800
message:
  * lisp/saveplace.el (toggle-save-place): Fix argument handling (tiny change)
modified:
  lisp/ChangeLog                 changelog-20091113204419-o5vbwnq5f7feedwu-1432
  lisp/saveplace.el              
saveplace.el-20091113204419-o5vbwnq5f7feedwu-622
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2014-02-28 05:29:45 +0000
+++ b/lisp/ChangeLog    2014-02-28 06:44:49 +0000
@@ -1,3 +1,8 @@
+2014-02-28  Andy Sawyer  <address@hidden>  (tiny change)
+
+       * saveplace.el (toggle-save-place):
+       Fix argument handling.  (Bug#16673)
+
 2014-02-28  Glenn Morris  <address@hidden>
 
        * minibuffer.el (completions-first-difference)

=== modified file 'lisp/saveplace.el'
--- a/lisp/saveplace.el 2014-02-21 00:35:08 +0000
+++ b/lisp/saveplace.el 2014-02-28 06:44:49 +0000
@@ -155,12 +155,12 @@
   (if (not (or buffer-file-name (and (derived-mode-p 'dired-mode)
                                     dired-directory)))
       (message "Buffer `%s' not visiting a file or directory" (buffer-name))
-    (if (and save-place (or (not parg) (<= parg 0)))
-       (progn
-         (message "No place will be saved in this file")
-         (setq save-place nil))
-      (message "Place will be saved")
-      (setq save-place t))))
+    (setq save-place (if parg
+                         (> (prefix-numeric-value parg) 0)
+                       (not save-place)))
+    (message (if save-place
+                 "Place will be saved"
+               "No place will be saved in this file"))))
 
 (declare-function dired-get-filename "dired" (&optional localp 
no-error-if-not-filep))
 


reply via email to

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