Skip to content
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

Report semantic tokens for HEREDOC (multi-line strings) #1220

Open
radeksimko opened this issue Mar 20, 2023 · 0 comments
Open

Report semantic tokens for HEREDOC (multi-line strings) #1220

radeksimko opened this issue Mar 20, 2023 · 0 comments
Labels
enhancement New feature or request textDocument/semanticTokens Semantic syntax highlighting workspace/semanticTokens

Comments

@radeksimko
Copy link
Member

Context

As noted in hashicorp/hcl-lang#186 (comment) we currently report multi-line strings the same way as single-line ones.

Screenshot 2023-03-20 at 16 46 55

Screenshot 2023-03-20 at 16 46 43

Proposal

Consider if reporting multi-line strings (HEREDOC) should be done through a different token, i.e. whether folks may want to highlight HEREDOC differently than simple strings.

Also, in spite of tests suggesting the HEREDOC range is reported correctly, the VS Code token inspector suggests we omit the initial << from the range. This may need to be investigated.

Screenshot 2023-03-20 at 16 48 43

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request textDocument/semanticTokens Semantic syntax highlighting workspace/semanticTokens
Projects
None yet
Development

No branches or pull requests

1 participant