@@ -547,7 +547,12 @@ If this is set to nil, `eldoc' will show only the symbol information."
547
547
:type 'boolean
548
548
:group 'lsp-mode)
549
549
550
- (defcustom lsp-references-exclude-definition nil
550
+ (define-obsolete-variable-alias
551
+ 'lsp-references-exclude-definition
552
+ 'lsp-references-exclude-declaration
553
+ "9.0.1")
554
+
555
+ (defcustom lsp-references-exclude-declaration nil
551
556
"If non-nil, exclude declarations when finding references."
552
557
:type 'boolean
553
558
:group 'lsp-mode)
@@ -6472,7 +6477,7 @@ perform the request synchronously."
6472
6477
(goto-char (cl-rest (or (assoc identifier lsp--symbols-cache)
6473
6478
(user-error "Unable to find symbol %s" identifier)))))
6474
6479
(lsp--locations-to-xref-items (lsp-request "textDocument/references"
6475
- (lsp--make-reference-params nil lsp-references-exclude-definition )))))
6480
+ (lsp--make-reference-params nil lsp-references-exclude-declaration )))))
6476
6481
6477
6482
(cl-defmethod xref-backend-apropos ((_backend (eql xref-lsp)) pattern)
6478
6483
(seq-map #'lsp--symbol-information-to-xref
@@ -6653,7 +6658,7 @@ REFERENCES? t when METHOD returns references."
6653
6658
"Find references of the symbol under point."
6654
6659
(interactive "P")
6655
6660
(lsp-find-locations "textDocument/references"
6656
- (list :context `(:includeDeclaration ,(lsp-json-bool (not (or exclude-declaration lsp-references-exclude-definition )))))
6661
+ (list :context `(:includeDeclaration ,(lsp-json-bool (not (or exclude-declaration lsp-references-exclude-declaration )))))
6657
6662
:display-action display-action
6658
6663
:references? t))
6659
6664
0 commit comments