You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A textmate grammar generated by the TextMateHighlightingFragment does not contain a rule for punctuation. As a result, any punctuation characters are picked up by the invalid rule and highlighted accordingly.
I've looked at the code and basically every keyword that does not match \w+ is ignored here and will then be picked up by the invalid rule.
The text was updated successfully, but these errors were encountered:
What textmate scope to use? The naming conventions aren't really clear regarding punctuation characters. VS Code uses different scopes for different punctuation characters, for example for typescript: keyword.operator.ternary.ts, punctuation.separator.comma.ts, meta.brace.square.ts, ...
Creating a punctuation rule for everything that is not matched here would be a simple solution to prevent valid tokens to be highlighted as errors. But it feels wrong to classify everything that does not match \w+ as punctuation.
For my personal use case, this simple solution with a scope named punctuation.languagename would be sufficient. And I guess it would be sufficient for most languages and certainly an improvement over the current situation.
A textmate grammar generated by the TextMateHighlightingFragment does not contain a rule for punctuation. As a result, any punctuation characters are picked up by the
invalid
rule and highlighted accordingly.I've looked at the code and basically every keyword that does not match
\w+
is ignored here and will then be picked up by theinvalid
rule.The text was updated successfully, but these errors were encountered: