generated from codemirror/lang-example
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
bgezer
committed
Jun 6, 2024
1 parent
0e21269
commit 73cab27
Showing
2 changed files
with
40 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
import { styleTags, tags as t } from "@lezer/highlight"; | ||
|
||
export const groovyHighlighting = styleTags({ | ||
null: t.null, | ||
instanceof: t.operatorKeyword, | ||
this: t.self, | ||
"new super assert open to with void": t.keyword, | ||
"class interface extends implements enum var": t.definitionKeyword, | ||
"module package import": t.moduleKeyword, | ||
"switch while for if else case default do break continue return try catch finally throw": | ||
t.controlKeyword, | ||
["requires exports opens uses provides public private protected static transitive abstract final " + | ||
"strictfp synchronized native transient volatile throws"]: t.modifier, | ||
IntegerLiteral: t.integer, | ||
FloatingPointLiteral: t.float, | ||
"StringLiteral TextBlock": t.string, | ||
CharacterLiteral: t.character, | ||
LineComment: t.lineComment, | ||
BlockComment: t.blockComment, | ||
BooleanLiteral: t.bool, | ||
PrimitiveType: t.standard(t.typeName), | ||
TypeName: t.typeName, | ||
Identifier: t.variableName, | ||
"MethodName/Identifier": t.function(t.variableName), | ||
Definition: t.definition(t.variableName), | ||
ArithOp: t.arithmeticOperator, | ||
LogicOp: t.logicOperator, | ||
BitOp: t.bitwiseOperator, | ||
CompareOp: t.compareOperator, | ||
AssignOp: t.definitionOperator, | ||
UpdateOp: t.updateOperator, | ||
Asterisk: t.punctuation, | ||
Label: t.labelName, | ||
"( )": t.paren, | ||
"[ ]": t.squareBracket, | ||
"{ }": t.brace, | ||
".": t.derefOperator, | ||
", ;": t.separator, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters