-
Notifications
You must be signed in to change notification settings - Fork 30.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"comment" semantic token type is overly broad vs the syntax types that it overrides when themeing #96712
Comments
(Experimental duplicate detection) |
I see that there's a If the intention is for the latter, I'll close this and open a bug against the LSP I'm using (rust-analyzer) to map |
Before adding a new type to the standard I'd suggest you to pioneer this for Rust first. It should be done with a new token type that extends the comment token type. {
"contributes": {
"semanticTokenTypes": [
{
"id": "docComment",
"superType": "comment",
"description": "A doc comment."
}
]
} Then for themes to support this, add a
|
I created #97063 to collect proposals for new standard token types/modifiers. |
Issue Type: Bug
There are multiple TextMate scopes for comments:
Rust:
comment.line.double-slash.rust
comment.line.documentation.rust
Java:
comment.line.double-slash.java
comment.block.javadoc.java
However, the semantic tokens only allow for
comment
, which breaks the ability to theme doc comments (comment.block.javadoc.java
,comment.line.documentation.rust
) separately from standard code comments.When semantic highlighting is enabled, all comments become
comment
to the theme.VS Code version: Code 1.44.2 (ff91584, 2020-04-16T17:07:18.473Z)
OS version: Darwin x64 19.3.0
Remote OS version: Linux x64 5.2.17-1rodete3-amd64
Extensions (16)
(3 theme extensions excluded)
The text was updated successfully, but these errors were encountered: