@@ -4956,13 +4956,13 @@ type Location, LocationLink, Location[] or LocationLink[]."
49564956             ((&Range :start right-start) (lsp--location-range right)))
49574957        (lsp--position-compare right-start left-start)))))
49584958
4959- (defun lsp--make-reference-params (&optional td-position include -declaration)
4959+ (defun lsp--make-reference-params (&optional td-position exclude -declaration)
49604960  "Make a ReferenceParam object.
49614961If TD-POSITION is non-nil, use it as TextDocumentPositionParams object instead.
4962- If INCLUDE -DECLARATION is non-nil, request the server to include declarations."
4962+ If EXCLUDE -DECLARATION is non-nil, request the server to include declarations."
49634963  (let ((json-false :json-false))
49644964    (plist-put (or td-position (lsp--text-document-position-params))
4965-                :context `(:includeDeclaration ,(or include-declaration  json-false )))))
4965+                :context `(:includeDeclaration ,(lsp- json-bool (not exclude-declaration) )))))
49664966
49674967(defun lsp--cancel-request (id)
49684968  "Cancel request with ID in all workspaces."
@@ -6152,11 +6152,11 @@ REFERENCES? t when METHOD returns references."
61526152                      :display-action display-action
61536153                      :references? t))
61546154
6155- (cl-defun lsp-find-references (&optional include -declaration &key display-action)
6155+ (cl-defun lsp-find-references (&optional exclude -declaration &key display-action)
61566156  "Find references of the symbol under point."
61576157  (interactive "P")
61586158  (lsp-find-locations "textDocument/references"
6159-                       (list :context `(:includeDeclaration ,(lsp-json-bool include -declaration)))
6159+                       (list :context `(:includeDeclaration ,(lsp-json-bool (not exclude -declaration) )))
61606160                      :display-action display-action
61616161                      :references? t))
61626162
0 commit comments