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
Right now people writing a grammar can add @Category annotations on their productions to get syntax highlighting in their IDE. It's been a bit of a mixed bag of what to write vs what you'll get. usethesource/rascal-language-servers#366 was a recent case of this misalignment.
After some more discussions with @jurgenvinju we came to the following design:
ParseTree gets a new ADT called Highlight
We use a fixed set of highlight categories (that happen to mirror the LSP SemanticTokenType categories)
Production rules can now be annotated with either the deprecated @Category or the new @Highlight=number()
The text was updated successfully, but these errors were encountered:
Thanks Davy. Minor note: the coding standard for tags is to start with lowercase, and for ADTs with uppercase. This helps to pry apart Highlight the ADT from @highlight=keyword() the tag name. Just like @synopsis{...}
Right now people writing a grammar can add
@Category
annotations on their productions to get syntax highlighting in their IDE. It's been a bit of a mixed bag of what to write vs what you'll get. usethesource/rascal-language-servers#366 was a recent case of this misalignment.After some more discussions with @jurgenvinju we came to the following design:
ParseTree
gets a new ADT calledHighlight
@Category
or the new@Highlight=number()
The text was updated successfully, but these errors were encountered: