]> git.eshelyaron.com Git - emacs.git/commitdiff
; * lisp/bookmark.el (bookmark-jump): Remove outdated workaround
authorEshel Yaron <me@eshelyaron.com>
Mon, 8 Jul 2024 20:33:55 +0000 (22:33 +0200)
committerEshel Yaron <me@eshelyaron.com>
Mon, 8 Jul 2024 20:33:55 +0000 (22:33 +0200)
lisp/bookmark.el

index 50767fce671fe705a703349ad02030c8a11c074f..6faaeba009ec5b05ebc900515fc6ea892b748b11 100644 (file)
@@ -1318,17 +1318,13 @@ BOOKMARK is usually a bookmark name (a string).  It can also be a
 bookmark record, but this is usually only done by programmatic callers.
 
 If DISPLAY-FUNC is non-nil, it is a function to invoke to display the
-bookmark.  It defaults to `pop-to-buffer-same-window'.  A typical value for
+bookmark.  It defaults to `switch-to-buffer'.  A typical value for
 DISPLAY-FUNC would be `switch-to-buffer-other-window'."
   (interactive
    (list (bookmark-completing-read "Jump to bookmark"
                                   bookmark-current-bookmark)))
-  (unless bookmark
-    (error "No bookmark specified"))
-  ;; Don't use `switch-to-buffer' because it would let the
-  ;; window-point override the bookmark's point when
-  ;; `switch-to-buffer-preserve-window-point' is non-nil.
-  (bookmark--jump-via bookmark (or display-func 'pop-to-buffer-same-window)))
+  (unless bookmark (error "No bookmark specified"))
+  (bookmark--jump-via bookmark (or display-func 'switch-to-buffer)))
 
 (put 'bookmark-jump 'minibuffer-action 'bookmark-display)