[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
emacs-28 c09ad0c: Fix the bug with duplicate entries in xref output
From: |
Dmitry Gutov |
Subject: |
emacs-28 c09ad0c: Fix the bug with duplicate entries in xref output |
Date: |
Fri, 24 Dec 2021 08:28:18 -0500 (EST) |
branch: emacs-28
commit c09ad0cabde922374c1a34350595a3141ab7f806
Author: Dmitry Gutov <dgutov@yandex.ru>
Commit: Dmitry Gutov <dgutov@yandex.ru>
Fix the bug with duplicate entries in xref output
* lisp/progmodes/etags.el (xref-backend-definitions): Make sure to
save the changed intermediate value of the list (bug#52734).
---
lisp/progmodes/etags.el | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el
index f53b09d..a63c3f3 100644
--- a/lisp/progmodes/etags.el
+++ b/lisp/progmodes/etags.el
@@ -2084,14 +2084,15 @@ file name, add `tag-partial-file-name-match-p' to the
list value.")
(definitions (etags--xref-find-definitions symbol))
same-file-definitions)
(when (and etags-xref-prefer-current-file file)
- (cl-delete-if
- (lambda (definition)
- (when (equal file
- (xref-location-group
- (xref-item-location definition)))
- (push definition same-file-definitions)
- t))
- definitions)
+ (setq definitions
+ (cl-delete-if
+ (lambda (definition)
+ (when (equal file
+ (xref-location-group
+ (xref-item-location definition)))
+ (push definition same-file-definitions)
+ t))
+ definitions))
(setq definitions (nconc (nreverse same-file-definitions)
definitions)))
definitions))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- emacs-28 c09ad0c: Fix the bug with duplicate entries in xref output,
Dmitry Gutov <=