Closed
Description
I've seen a some conversations that imply that semantic tokens obsolete DiagnosticTag:
- feat(diagnostic): add support for tags neovim/neovim#22747 (comment): "the diagnostics themselves are just a precursor to semantic tokens (which came after)."
- reportUnusedVariable ignore pattern pyright#1118 (comment): "Pyright's implementation of this functionality does indeed predate the introduction of semantic tokens. [...] If you'd like to build your own language server on top of pyright (e.g. to convert "unreferenced code" tagged hints into semantic tokens), you're welcome to do so."
- reportUnusedVariable ignore pattern pyright#1118 (comment): "for Pyright to switch these tagged diagnostics to semantic tokens"
- clangd even has a (currently undocumented) extension to the Language Server Protocol that adds a new
textDocument/inactiveRegions
request: Document the textDocument/inactiveRegions extension llvm/clangd-www#104. I think this is implemented using the semantic tokens api, but I haven't checked. - SemanticTokensModifier: Add
unused
token modifier vscode-languageserver-node#604
But the discussion over on microsoft/vscode#92157 has a comment from @alexdima that says:
I am not in favor of adding competing API that gives two distinct ways to achieve the same effect.
So I'm confused. @HighCommander4, maybe you know the answer? Why does clangd need an extension to the Language Server Protocol to do this? Is it related to marking large regions of code as unused?
Metadata
Metadata
Assignees
Labels
No labels