aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Colascione2015-05-04 15:40:55 -0700
committerDaniel Colascione2015-05-04 15:41:36 -0700
commit1ddb81a686a1e2cd6898cbd8b65878a74579ca71 (patch)
tree99fdd9b47d43ca5c844453a65c97e1550d3d2afc
parent943c45f68b7b954f311ec3c1c35ed21830223333 (diff)
downloademacs-1ddb81a686a1e2cd6898cbd8b65878a74579ca71.tar.gz
emacs-1ddb81a686a1e2cd6898cbd8b65878a74579ca71.zip
Fix previous commit
-rw-r--r--lisp/simple.el9
1 files changed, 5 insertions, 4 deletions
diff --git a/lisp/simple.el b/lisp/simple.el
index 9f42f00b149..47c9cd30c17 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -4873,7 +4873,7 @@ store it in a Lisp variable. Example:
4873(defun save-mark-and-excursion--save () 4873(defun save-mark-and-excursion--save ()
4874 (cons 4874 (cons
4875 (let ((mark (mark-marker))) 4875 (let ((mark (mark-marker)))
4876 (and mark (marker-position mark) (copy-marker mark))) 4876 (and (marker-position mark) (copy-marker mark)))
4877 mark-active)) 4877 mark-active))
4878 4878
4879(defun save-mark-and-excursion--restore (saved-mark-info) 4879(defun save-mark-and-excursion--restore (saved-mark-info)
@@ -4883,17 +4883,18 @@ store it in a Lisp variable. Example:
4883 (saved-mark-active (cdr saved-mark-info))) 4883 (saved-mark-active (cdr saved-mark-info)))
4884 ;; Mark marker 4884 ;; Mark marker
4885 (if (null saved-mark) 4885 (if (null saved-mark)
4886 (set-marker (mark-marker nil)) 4886 (set-marker (mark-marker) nil)
4887 (setf nmark (marker-position saved-mark)) 4887 (setf nmark (marker-position saved-mark))
4888 (set-marker (mark-marker) nmark) 4888 (set-marker (mark-marker) nmark)
4889 (set-marker saved-mark nil)) 4889 (set-marker saved-mark nil))
4890 ;; Mark active 4890 ;; Mark active
4891 (let ((cur-mark-active mark-active)) 4891 (let ((cur-mark-active mark-active))
4892 (setf mark-active saved-mark-active) 4892 (setq mark-active saved-mark-active)
4893 ;; If mark is active now, and either was not active or was at a 4893 ;; If mark is active now, and either was not active or was at a
4894 ;; different place, run the activate hook. 4894 ;; different place, run the activate hook.
4895 (if saved-mark-active 4895 (if saved-mark-active
4896 (unless (eq omark nmark) 4896 (when (or (not cur-mark-active)
4897 (not (eq omark nmark)))
4897 (run-hooks 'activate-mark-hook)) 4898 (run-hooks 'activate-mark-hook))
4898 ;; If mark has ceased to be active, run deactivate hook. 4899 ;; If mark has ceased to be active, run deactivate hook.
4899 (when cur-mark-active 4900 (when cur-mark-active