hokein added a comment.

sorry for the looong delay, I was OOO for a few weeks before.

The patch looks fine, my concern is that how do we support this `line` 
extension when LSP provides a standard implementation -- there is some 
significant progress about semantic highlighting on VSCode,  VSCode now 
provides an experimental semantic token API 
<https://github.com/microsoft/vscode/wiki/Semantic-Highlighting-Overview>, but 
no LSP binding yet (is not far away I think). When it is ready, we'd like to 
switch to that and get rid of our own implementation. Looking at the API there, 
it seems like we could make the line-style scope name `meta.disable` clangd 
specific, and define our own style.



================
Comment at: 
clang-tools-extra/clangd/clients/clangd-vscode/src/semantic-highlighting.ts:293
       });
+      if (line.isInactive) {
+        inactiveRanges.push(new vscode.Range(
----------------
 another solution that requires minimal changes (but more hacky) is that, since 
clangd emits a `meta.disabled` token with line-set-only range, we could inject 
the `inactiveCodeDecorationType` to the `meta.disabled` slot of 
`Highlighter::decorationTypes`, and everything should work.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67537/new/

https://reviews.llvm.org/D67537



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to