[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master fd24450 2/2: xref-goto-xref: Highlight the exact sy
From: |
Dmitry Gutov |
Subject: |
[Emacs-diffs] master fd24450 2/2: xref-goto-xref: Highlight the exact symbol after the jump |
Date: |
Sun, 23 Dec 2018 22:11:53 -0500 (EST) |
branch: master
commit fd244507c5ea1e7e425f09585fcf15cc90598e9b
Author: Dmitry Gutov <address@hidden>
Commit: Dmitry Gutov <address@hidden>
xref-goto-xref: Highlight the exact symbol after the jump
* lisp/progmodes/xref.el (xref-goto-xref): Bind
'xref--current-item' to highlight the exact symbol after the jump
and not the whole line.
---
lisp/progmodes/xref.el | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el
index a0a704f..c71802c 100644
--- a/lisp/progmodes/xref.el
+++ b/lisp/progmodes/xref.el
@@ -551,9 +551,10 @@ SELECT is `quit', also quit the *xref* window."
Non-interactively, non-nil QUIT means to first quit the *xref*
buffer."
(interactive)
- (let ((buffer (current-buffer))
- (xref (or (xref--item-at-point)
- (user-error "No reference at point"))))
+ (let* ((buffer (current-buffer))
+ (xref (or (xref--item-at-point)
+ (user-error "No reference at point")))
+ (xref--current-item xref))
(xref--show-location (xref-item-location xref) (if quit 'quit t))
(next-error-found buffer (current-buffer))))