| 1 |
(identifier) @variable |
| 2 |
(return "return" @keyword.control.return) |
| 3 |
(global ["VAR" "CONST"] @keyword.storage.type |
| 4 |
"=" @operator) |
| 5 |
(temp_def "temp" @keyword |
| 6 |
name: (identifier) @variable.member) |
| 7 |
(include "INCLUDE" @keyword.control.import |
| 8 |
(path) @string.special.path) |
| 9 |
(external "EXTERNAL" @keyword |
| 10 |
(identifier) @function) |
| 11 |
(todo_comment "TODO" @keyword ":" @comment) @comment |
| 12 |
(code "~" @keyword.directive) |
| 13 |
|
| 14 |
(binary "+" @operator) |
| 15 |
(binary "-" @operator) |
| 16 |
(binary "*" @operator) |
| 17 |
(binary "/" @operator) |
| 18 |
(binary "?" @operator) |
| 19 |
(binary "!?" @operator) |
| 20 |
(binary "^" @operator) |
| 21 |
(binary "==" @operator) |
| 22 |
(binary "!=" @operator) |
| 23 |
(binary "||" @operator) |
| 24 |
(binary "&&" @operator) |
| 25 |
(binary "<=" @operator) |
| 26 |
(binary ">=" @operator) |
| 27 |
(binary "<" @operator) |
| 28 |
(binary ">" @operator) |
| 29 |
(binary "%" @operator) |
| 30 |
(binary "and" @keyword.operator) |
| 31 |
(binary "or" @keyword.operator) |
| 32 |
(binary "has" @keyword.operator) |
| 33 |
(binary "hasnt" @keyword.operator) |
| 34 |
(binary "mod" @keyword.operator) |
| 35 |
|
| 36 |
(postfix "++" @operator) |
| 37 |
(postfix "--" @operator) |
| 38 |
|
| 39 |
(unary "!" @operator) |
| 40 |
(unary "-" @operator) |
| 41 |
(unary "not" @keyword.operator) |
| 42 |
|
| 43 |
(assignment ["=" "+=" "-="]) @operator |
| 44 |
|
| 45 |
(choice_only ["[" "]"] @punctuation.bracket) |
| 46 |
(label ["(" ")"] @punctuation.bracket name: (_) @label) |
| 47 |
|
| 48 |
["{" "}"] @punctuation.bracket |
| 49 |
|
| 50 |
["," "|" ":"] @punctuation.delimiter |
| 51 |
|
| 52 |
(call (identifier) @function.builtin |
| 53 |
(#any-of? @function.builtin |
| 54 |
|
| 55 |
"LIST_VALUE" |
| 56 |
"LIST_COUNT" |
| 57 |
"LIST_MIN" |
| 58 |
"LIST_MAX" |
| 59 |
"LIST_RANDOM" |
| 60 |
"LIST_RANGE" |
| 61 |
"LIST_INVERT" |
| 62 |
|
| 63 |
"CHOICE_COUNT" |
| 64 |
"TURNS" |
| 65 |
"TURNS_SINCE" |
| 66 |
"LIST_FOO" |
| 67 |
"SEED_RANDOM")) |
| 68 |
(call (identifier) @function) |
| 69 |
(call ["(" ")"] @punctuation.bracket) |
| 70 |
|
| 71 |
(knot "==" @markup.heading.1 (identifier) @label) |
| 72 |
(knot "function" @keyword.function |
| 73 |
(identifier) @function) |
| 74 |
|
| 75 |
(stitch "=" @markup.heading.2 (identifier) @label) |
| 76 |
|
| 77 |
(choice_mark) @markup.list.numbered |
| 78 |
(gather_mark) @markup.list.unnumbered |
| 79 |
|
| 80 |
(cond_arm "-" @keyword.control.conditional) |
| 81 |
(alt_arm "-" @keyword.control.repeat) |
| 82 |
(else) @constant.builtin |
| 83 |
|
| 84 |
(list "LIST" @keyword.storage.type |
| 85 |
(identifier) @type.enum |
| 86 |
"=" @operator) |
| 87 |
|
| 88 |
(list_value_def (identifier) @type.enum.variant) |
| 89 |
|
| 90 |
(list_values (identifier) @type.enum.variant) |
| 91 |
(list_values |
| 92 |
(qualified_name |
| 93 |
. (identifier) @type.enum |
| 94 |
(identifier) @type.enum.variant)) |
| 95 |
|
| 96 |
(glue) @keyword |
| 97 |
|
| 98 |
["->" "->->" "<-"] @keyword.control |
| 99 |
|
| 100 |
(divert (identifier) @label) |
| 101 |
(divert (identifier) @constant.builtin |
| 102 |
(#any-of? @constant.builtin "END" "DONE")) |
| 103 |
|
| 104 |
(divert (call (identifier) @label)) |
| 105 |
(divert (call (qualified_name (identifier) @label))) |
| 106 |
|
| 107 |
(thread [(identifier) (call)] @label) |
| 108 |
|
| 109 |
|
| 110 |
(params ["(" ")"] @punctuation.bracket) |
| 111 |
(param |
| 112 |
"ref"? @keyword.storage.modifier |
| 113 |
value: [ (identifier) @variable.parameter |
| 114 |
(divert (identifier) @variable.parameter) ]?) |
| 115 |
|
| 116 |
(multiline_alternatives ["shuffle" "stopping" "cycle" "once"] @keyword.control.repeat) |
| 117 |
(alternatives ["&" "$" "~" "!"] @keyword.control.repeat) |
| 118 |
|
| 119 |
(line_comment) @comment.line |
| 120 |
(block_comment) @comment.block |
| 121 |
|
| 122 |
(qualified_name "." @punctuation.delimiter) |
| 123 |
(string) @string |
| 124 |
|
| 125 |
(number) @constant.numeric |
| 126 |
(boolean) @keyword.builtin.boolean |
| 127 |
|
| 128 |
(tag "#" @punctuation.special) @tag |