summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorDmitry Gutov <dgutov@yandex.ru>2021-09-05 03:52:29 +0300
committerDmitry Gutov <dgutov@yandex.ru>2021-09-05 03:52:29 +0300
commit94530e7ea9450e6b3eff255b80f76f8f7b051632 (patch)
treef7fcfab127f103e3b6d77195ad012c258145ada8 /lisp
parentc2983375055f1f8326734322d35dc45e83d47046 (diff)
downloademacs-94530e7ea9450e6b3eff255b80f76f8f7b051632.tar.gz
emacs-94530e7ea9450e6b3eff255b80f76f8f7b051632.tar.bz2
emacs-94530e7ea9450e6b3eff255b80f76f8f7b051632.zip
Belated fix
* lisp/progmodes/xref.el: (xref--show-xref-buffer): Fix support for xref-auto-jump-to-first-xref.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/progmodes/xref.el9
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el
index e959f601e94..86cbdf1fb98 100644
--- a/lisp/progmodes/xref.el
+++ b/lisp/progmodes/xref.el
@@ -1,7 +1,7 @@
;;; xref.el --- Cross-referencing commands -*-lexical-binding:t-*-
;; Copyright (C) 2014-2021 Free Software Foundation, Inc.
-;; Version: 1.2.0
+;; Version: 1.2.1
;; Package-Requires: ((emacs "26.1"))
;; This is a GNU ELPA :core package. Avoid functionality that is not
@@ -1042,13 +1042,16 @@ Return an alist of the form ((FILENAME . (XREF ...)) ...)."
(assoc-default 'fetched-xrefs alist)
(funcall fetcher)))
(xref-alist (xref--analyze xrefs))
- (dd default-directory))
+ (dd default-directory)
+ buf)
(with-current-buffer (get-buffer-create xref-buffer-name)
(setq default-directory dd)
(xref--xref-buffer-mode)
(xref--show-common-initialize xref-alist fetcher alist)
(pop-to-buffer (current-buffer))
- (current-buffer))))
+ (setq buf (current-buffer)))
+ (xref--auto-jump-first buf (assoc-default 'auto-jump alist))
+ buf))
(defun xref--project-root (project)
(if (fboundp 'project-root)