[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 5ce082d 2/2: ; xref--create-fetcher: Add some furth
From: |
Dmitry Gutov |
Subject: |
[Emacs-diffs] master 5ce082d 2/2: ; xref--create-fetcher: Add some further clarification |
Date: |
Sat, 25 May 2019 17:19:41 -0400 (EDT) |
branch: master
commit 5ce082d636a6e321994cc807d3dea9374e17d34b
Author: Dmitry Gutov <address@hidden>
Commit: Dmitry Gutov <address@hidden>
; xref--create-fetcher: Add some further clarification
---
lisp/progmodes/xref.el | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el
index 090618f..b2f841b 100644
--- a/lisp/progmodes/xref.el
+++ b/lisp/progmodes/xref.el
@@ -929,6 +929,12 @@ the xref backend method indicated by KIND and passes ARG
to it."
(method (intern (format "xref-backend-%s" kind))))
(lambda ()
(save-excursion
+ ;; Xref methods are generally allowed to depend on the text
+ ;; around point, not just on their explicit arguments.
+ ;;
+ ;; There is only so much we can do, however, to recreate that
+ ;; context, given that the user is free to change the buffer
+ ;; contents freely in the meantime.
(when (buffer-live-p orig-buffer)
(set-buffer orig-buffer)
(ignore-errors (goto-char orig-position)))