| 1 |
|
| 2 |
(identifier) @variable |
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
(open |
| 7 |
namespace: (identifier) @namespace) |
| 8 |
(namespace |
| 9 |
name: (identifier) @namespace) |
| 10 |
(section |
| 11 |
name: (identifier) @namespace) |
| 12 |
|
| 13 |
|
| 14 |
((identifier) @type |
| 15 |
(#match? @type "^[A-Z]")) |
| 16 |
|
| 17 |
(arrow) @type |
| 18 |
(product) @type |
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
[ |
| 23 |
"abbrev" |
| 24 |
"def" |
| 25 |
"theorem" |
| 26 |
"constant" |
| 27 |
"instance" |
| 28 |
"axiom" |
| 29 |
"example" |
| 30 |
"inductive" |
| 31 |
"structure" |
| 32 |
"class" |
| 33 |
|
| 34 |
"deriving" |
| 35 |
|
| 36 |
"section" |
| 37 |
"namespace" |
| 38 |
] @keyword |
| 39 |
|
| 40 |
(attributes |
| 41 |
(identifier) @function) |
| 42 |
|
| 43 |
(abbrev |
| 44 |
name: (identifier) @type) |
| 45 |
(def |
| 46 |
name: (identifier) @function) |
| 47 |
(theorem |
| 48 |
name: (identifier) @function) |
| 49 |
(constant |
| 50 |
name: (identifier) @type) |
| 51 |
(instance |
| 52 |
name: (identifier) @function) |
| 53 |
(instance |
| 54 |
type: (identifier) @type) |
| 55 |
(axiom |
| 56 |
name: (identifier) @function) |
| 57 |
(structure |
| 58 |
name: (identifier) @type) |
| 59 |
(structure |
| 60 |
extends: (identifier) @type) |
| 61 |
|
| 62 |
(where_decl |
| 63 |
type: (identifier) @type) |
| 64 |
|
| 65 |
(proj |
| 66 |
name: (identifier) @field) |
| 67 |
|
| 68 |
(binders |
| 69 |
type: (identifier) @type) |
| 70 |
|
| 71 |
["if" "then" "else"] @keyword.control.conditional |
| 72 |
|
| 73 |
["for" "in" "do"] @keyword.control.repeat |
| 74 |
|
| 75 |
"import" @keyword.control.import |
| 76 |
|
| 77 |
|
| 78 |
|
| 79 |
[ |
| 80 |
"!" |
| 81 |
"$" |
| 82 |
"%" |
| 83 |
"&&" |
| 84 |
"*" |
| 85 |
"*>" |
| 86 |
"+" |
| 87 |
"++" |
| 88 |
"-" |
| 89 |
"/" |
| 90 |
"::" |
| 91 |
":=" |
| 92 |
"<" |
| 93 |
"<$>" |
| 94 |
"<*" |
| 95 |
"<*>" |
| 96 |
"<=" |
| 97 |
"<|" |
| 98 |
"<|>" |
| 99 |
"=" |
| 100 |
"==" |
| 101 |
"=>" |
| 102 |
">" |
| 103 |
">" |
| 104 |
">=" |
| 105 |
">>" |
| 106 |
">>=" |
| 107 |
"@" |
| 108 |
"^" |
| 109 |
"|>" |
| 110 |
"|>." |
| 111 |
"||" |
| 112 |
"←" |
| 113 |
"→" |
| 114 |
"↔" |
| 115 |
"∘" |
| 116 |
"∧" |
| 117 |
"∨" |
| 118 |
"≠" |
| 119 |
"≤" |
| 120 |
"≥" |
| 121 |
] @operator |
| 122 |
|
| 123 |
[ |
| 124 |
"@&" |
| 125 |
] @operator |
| 126 |
|
| 127 |
[ |
| 128 |
"attribute" |
| 129 |
"by" |
| 130 |
"end" |
| 131 |
"export" |
| 132 |
"extends" |
| 133 |
"fun" |
| 134 |
"let" |
| 135 |
"have" |
| 136 |
"match" |
| 137 |
"open" |
| 138 |
"return" |
| 139 |
"universe" |
| 140 |
"variable" |
| 141 |
"where" |
| 142 |
"with" |
| 143 |
"λ" |
| 144 |
(hash_command) |
| 145 |
(prelude) |
| 146 |
(sorry) |
| 147 |
] @keyword |
| 148 |
|
| 149 |
[ |
| 150 |
"prefix" |
| 151 |
"infix" |
| 152 |
"infixl" |
| 153 |
"infixr" |
| 154 |
"postfix" |
| 155 |
"notation" |
| 156 |
"macro_rules" |
| 157 |
"syntax" |
| 158 |
"elab" |
| 159 |
"builtin_initialize" |
| 160 |
] @keyword |
| 161 |
|
| 162 |
[ |
| 163 |
"noncomputable" |
| 164 |
"partial" |
| 165 |
"private" |
| 166 |
"protected" |
| 167 |
"unsafe" |
| 168 |
] @keyword |
| 169 |
|
| 170 |
[ |
| 171 |
"apply" |
| 172 |
"exact" |
| 173 |
"rewrite" |
| 174 |
"rw" |
| 175 |
"simp" |
| 176 |
(trivial) |
| 177 |
] @keyword |
| 178 |
|
| 179 |
[ |
| 180 |
"catch" |
| 181 |
"finally" |
| 182 |
"try" |
| 183 |
] @exception |
| 184 |
|
| 185 |
((apply |
| 186 |
name: (identifier) @exception) |
| 187 |
(#match? @exception "throw")) |
| 188 |
|
| 189 |
[ |
| 190 |
"unless" |
| 191 |
"mut" |
| 192 |
] @keyword |
| 193 |
|
| 194 |
[(true) (false)] @constant.builtin.boolean |
| 195 |
|
| 196 |
(number) @constant.numeric.integer |
| 197 |
(float) @constant.numeric.float |
| 198 |
|
| 199 |
(comment) @comment |
| 200 |
(char) @constant.character |
| 201 |
(string) @string |
| 202 |
(interpolated_string) @string |
| 203 |
|
| 204 |
|
| 205 |
|
| 206 |
(interpolation) @none |
| 207 |
|
| 208 |
(interpolation |
| 209 |
"{" @punctuation.special |
| 210 |
"}" @punctuation.special) |
| 211 |
|
| 212 |
["(" ")" "[" "]" "{" "}" "⟨" "⟩"] @punctuation.bracket |
| 213 |
|
| 214 |
["|" "," "." ":" ";"] @punctuation.delimiter |
| 215 |
|
| 216 |
(sorry) @error |