[clang-tools-extra] [clangd] Add languages as server capabilities (PR #75633)
kadir çetinkaya via cfe-commits
cfe-commits at lists.llvm.org
Thu Jun 12 06:27:00 PDT 2025
kadircet wrote:
I am afraid exposing this in server capabilities might be too convoluted.
IIUC, we're trying to figure out if clangd should be used for documents for language `X`. We need to figure this out **before** clangd's proper initialization, so that we can decide which `documentSelector`s to provide.
Hence spawning clangd with simple modes like `--version` etc. to figure out this information is OK, but I don't think we should pay the complexity of starting clangd, providing it with a `initialize request` and then parsing the output to decide and kill the language server afterwards (moreover, even if we did, I don't think this mechanism would be meaningful/usable by any other LSP client).
https://github.com/llvm/llvm-project/pull/75633
More information about the cfe-commits
mailing list