The cquery language server supports some custom methods $cquery/base $cquery/derived $cquery/callers $cquery/vars. The params used in request/response are identical to textDocument/references: send TextDocumentPositionParams and receive Location[].
(defun my-cquery/base () (interactive) (lsp-ui-peek-find-custom 'base "$cquery/base"))
(defun my-cquery/callers () (interactive) (lsp-ui-peek-find-custom 'callers "$cquery/callers"))
(defun my-cquery/derived () (interactive) (lsp-ui-peek-find-custom 'derived "$cquery/derived"))
(defun my-cquery/vars () (interactive) (lsp-ui-peek-find-custom 'vars "$cquery/vars"))
This is actually more useful to other issues for Vim users. They currently just don't know there are other cross references.
Thanks for supporting these methods.. But is there a more general approach? I can think of cross reference extension s from other servers...
No, not yet.
Will make it generic only when there are more requests coming in.
I am using my fork of cquery now https://github.com/MaskRay/ccls and it has been added to archlinuxcn/ccls-git
I've written some motivation for the fork in https://github.com/MaskRay/emacs-ccls/issues/1
The extensions it supports:
$cquery/derived -> (textDocument/implementation)
$cquery/vars -> -> $ccls/vars
$cquery/base -> $ccls/base
$cquery/callers -> $ccls/callers
It would be much appreciated if you could add a generic method
Most helpful comment
I am using my fork of cquery now https://github.com/MaskRay/ccls and it has been added to archlinuxcn/ccls-git
I've written some motivation for the fork in https://github.com/MaskRay/emacs-ccls/issues/1
The extensions it supports:
It would be much appreciated if you could add a generic method