[clangd-dev] Landing support for LSP protocol extensions?
Nathan Ridge via clangd-dev
clangd-dev at lists.llvm.org
Thu Jan 10 16:48:25 PST 2019
I've written a patch  to add support to clangd for the "textDocument/superTypes" request, which, given the location of a symbol naming a class type, returns information about its base classes.
This is not part of the LSP specification yet, though it has been proposed for addition , and has been implemented in at least one client (Theia , not merged yet).
(There is also a "textDocument/subTypes" request in the proposal, which returns information about derived classes. That's more challenging to implement; stay tuned for a separate post about that.)
Is clangd interested in support for protocol extensions like this landing, in any form, prior to their standardization in LSP?
If so, are there any measures that should be taken to reflect that the protocol is not yet standard? For example:
* cquery (another C++ language server ) puts non-standard protocols into a "$cquery" namespace, e.g. "$cquery/typeHierarchy" rather than "textDocument/typeHierarchy". clangd could potentially do the same.
* The protocol could be available under the standard name, but behind a command-line flag and not enabled by default.
Any thoughts on this subject are appreciated!
More information about the clangd-dev