github-linguist 5.0.0 → 5.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/bin/git-linguist +10 -2
  3. data/bin/linguist +26 -9
  4. data/grammars/config.xcompose.json +83 -0
  5. data/grammars/hint.haskell.json +21 -30
  6. data/grammars/hint.message.haskell.json +21 -30
  7. data/grammars/hint.type.haskell.json +21 -30
  8. data/grammars/source.bsl.json +42 -28
  9. data/grammars/source.cs.json +656 -131
  10. data/grammars/source.csound-document.json +142 -25
  11. data/grammars/source.csound-score.json +13 -10
  12. data/grammars/source.csound.json +136 -81
  13. data/grammars/source.css.json +1501 -331
  14. data/grammars/source.css.less.json +3 -3
  15. data/grammars/source.d.json +60 -44
  16. data/grammars/source.gn.json +240 -138
  17. data/grammars/source.graphql.json +781 -155
  18. data/grammars/source.haskell.json +21 -30
  19. data/grammars/source.js.json +46 -46
  20. data/grammars/source.mask.json +1 -1
  21. data/grammars/source.perl6fe.json +1151 -763
  22. data/grammars/source.python.json +45 -23
  23. data/grammars/source.quoting.perl6fe.json +2170 -0
  24. data/grammars/source.reason.json +296 -0
  25. data/grammars/source.regexp.perl6fe.json +27 -0
  26. data/grammars/source.rust.json +522 -125
  27. data/grammars/source.sdbl.json +2 -2
  28. data/grammars/source.shell.json +125 -161
  29. data/grammars/source.solidity.json +137 -0
  30. data/grammars/source.ts.json +385 -137
  31. data/grammars/source.tsx.json +394 -167
  32. data/grammars/source.yaml.json +176 -171
  33. data/grammars/text.html.php.blade.json +2 -2
  34. data/grammars/text.tex.latex.haskell.json +1 -10
  35. data/lib/linguist/generated.rb +50 -4
  36. data/lib/linguist/heuristics.rb +1 -1
  37. data/lib/linguist/language.rb +12 -8
  38. data/lib/linguist/languages.json +1 -1
  39. data/lib/linguist/languages.yml +38 -1
  40. data/lib/linguist/samples.json +4605 -581
  41. data/lib/linguist/vendor.yml +6 -0
  42. data/lib/linguist/version.rb +1 -1
  43. metadata +10 -7
  44. data/grammars/source.hy.json +0 -270
@@ -297,13 +297,13 @@
297
297
  "begin": "{",
298
298
  "beginCaptures": {
299
299
  "0": {
300
- "name": "punctuation.section.property-list.begin.css"
300
+ "name": "punctuation.section.property-list.begin.bracket.curly.css"
301
301
  }
302
302
  },
303
303
  "end": "}",
304
304
  "endCaptures": {
305
305
  "0": {
306
- "name": "punctuation.section.property-list.end.css"
306
+ "name": "punctuation.section.property-list.end.bracket.curly.css"
307
307
  }
308
308
  },
309
309
  "name": "meta.property-list.css",
@@ -487,7 +487,7 @@
487
487
  },
488
488
  "commas": {
489
489
  "match": ",",
490
- "name": "punctuation.separator.list.css"
490
+ "name": "punctuation.separator.list.comma.css"
491
491
  },
492
492
  "brace_round": {
493
493
  "match": "\\(|\\)",
@@ -73,47 +73,33 @@
73
73
  "name": "meta.control.conditional.d"
74
74
  },
75
75
  {
76
- "begin": "(?x)(?<=^|\\}|;)\\s*\n\t\t\t\t\t((?:\\b(public|private|protected|static|final|synchronized|abstract|export|shared)\\b\\s*)*) # modifier\n\t\t\t\t\t(class|interface)\\s+\n\t\t\t\t\t(\\w+)\\s* # identifier\n\t\t\t\t\t(?:\\(\\s*([^\\)]+)\\s*\\)|)\\s* # Template type\n\t\t\t\t\t(?:\n\t\t\t\t\t \\s*(:)\\s*\n\t\t\t\t\t (\\w+)\n\t\t\t\t\t (?:\\s*,\\s*(\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(\\w+))?\n\t\t\t\t\t)? # super class\n\t\t\t\t\t",
76
+ "begin": "(?x)(?<=^|\\}|;)\\s*\n\t\t\t\t\t(?<meta_modifier>\n\t\t\t\t\t\t(?:\n\t\t\t\t\t\t\t(?:\n\t\t\t\t\t\t\t\t(?:(?:\\b(?:public|private|protected|static|final|synchronized|abstract|export|shared)\\b)) |\n\t\t\t\t\t\t\t\t(?:\\b(?:extern)\\b(?:\\s*\\(\\s*(?:(?:(?:C\\+\\+)(?:\\s*,\\s*[A-Za-z_][A-Za-z0-9._]*)?)|\\b(?:C|D|Windows|Pascal|System|Objective-C)\\b)\\s*\\))?)\n\t\t\t\t\t\t\t)\\s*\n\t\t\t\t\t\t)*\n\t\t\t\t\t)\n\t\t\t\t\t(?<structure>class|interface)\\s+\n\t\t\t\t\t(?<identifier>\\w+)\\s* # identifier\n\t\t\t\t\t(?:\\(\\s*(?<template_params>[^\\)]+)\\s*\\)|)\\s* # Template type\n\t\t\t\t\t(?:\n\t\t\t\t\t \\s*(?<inheritance_separator>:)\\s*\n\t\t\t\t\t (?<inherited>\\w+)\n\t\t\t\t\t (?:\\s*,\\s*(?<inherited>\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(?<inherited>\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(?<inherited>\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(?<inherited>\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(?<inherited>\\w+))?\n\t\t\t\t\t (?:\\s*,\\s*(?<inherited>\\w+))?\n\t\t\t\t\t)? # super class\n\t\t\t\t\t",
77
77
  "beginCaptures": {
78
- "1": {
79
- "name": "storage.modifier.d"
80
- },
81
- "10": {
82
- "name": "entity.other.inherited-class.d"
78
+ "identifier": {
79
+ "name": "entity.name.type.class.d"
83
80
  },
84
- "11": {
85
- "name": "entity.other.inherited-class.d"
81
+ "inheritance_separator": {
82
+ "name": "punctuation.separator.inheritance.d"
86
83
  },
87
- "12": {
84
+ "inherited": {
88
85
  "name": "entity.other.inherited-class.d"
89
86
  },
90
- "13": {
91
- "name": "entity.other.inherited-class.d"
87
+ "meta_modifier": {
88
+ "patterns": [
89
+ {
90
+ "include": "#meta-modifier"
91
+ }
92
+ ]
92
93
  },
93
- "3": {
94
+ "structure": {
94
95
  "name": "storage.type.structure.d"
95
96
  },
96
- "4": {
97
- "name": "entity.name.type.class.d"
98
- },
99
- "5": {
97
+ "template_params": {
100
98
  "patterns": [
101
99
  {
102
100
  "include": "$base"
103
101
  }
104
102
  ]
105
- },
106
- "6": {
107
- "name": "punctuation.separator.inheritance.d"
108
- },
109
- "7": {
110
- "name": "entity.other.inherited-class.d"
111
- },
112
- "8": {
113
- "name": "entity.other.inherited-class.d"
114
- },
115
- "9": {
116
- "name": "entity.other.inherited-class.d"
117
103
  }
118
104
  },
119
105
  "end": "(?={|;)",
@@ -140,18 +126,22 @@
140
126
  ]
141
127
  },
142
128
  {
143
- "begin": "(?x)(?<=^|\\}|;)\\s*\n\t\t\t\t\t((?:\\b(public|private|protected|static|final|synchronized|abstract|export|shared)\\b\\s*)*) # modifier\n\t\t\t\t\t(struct)\\s+\n\t\t\t\t\t(\\w+)\\s* # identifier\n\t\t\t\t\t(?:\\(\\s*([^\\)]+)\\s*\\)|)\\s* # Template type\n\t\t\t\t\t",
129
+ "begin": "(?x)(?<=^|\\}|;)\\s*\n\t\t\t\t\t(?<meta_modifier>\n\t\t\t\t\t\t(?:\n\t\t\t\t\t\t\t(?:\n\t\t\t\t\t\t\t\t(?:(?:\\b(?:public|private|protected|static|final|synchronized|abstract|export|shared)\\b)) |\n\t\t\t\t\t\t\t\t(?:\\b(?:extern)\\b(?:\\s*\\(\\s*(?:(?:(?:C\\+\\+)(?:\\s*,\\s*[A-Za-z_][A-Za-z0-9._]*)?)|\\b(?:C|D|Windows|Pascal|System|Objective-C)\\b)\\s*\\))?)\n\t\t\t\t\t\t\t)\\s*\n\t\t\t\t\t\t)*\n\t\t\t\t\t)\n\t\t\t\t\t(?<structure>struct)\\s+\n\t\t\t\t\t(?<identifier>\\w+)\\s*\n\t\t\t\t\t(?:\\(\\s*(?<template_params>[^\\)]+)\\s*\\)|)\\s*\n\t\t\t\t\t",
144
130
  "beginCaptures": {
145
- "1": {
146
- "name": "storage.modifier.d"
131
+ "identifier": {
132
+ "name": "entity.name.type.struct.d"
147
133
  },
148
- "3": {
149
- "name": "storage.type.structure.d"
134
+ "meta_modifier": {
135
+ "patterns": [
136
+ {
137
+ "include": "#meta-modifier"
138
+ }
139
+ ]
150
140
  },
151
- "4": {
152
- "name": "entity.name.type.struct.d"
141
+ "structure": {
142
+ "name": "storage.type.structure.d"
153
143
  },
154
- "5": {
144
+ "template_params": {
155
145
  "patterns": [
156
146
  {
157
147
  "include": "$base"
@@ -272,16 +262,14 @@
272
262
  {
273
263
  "captures": {
274
264
  "1": {
275
- "name": "keyword.other.external.d"
276
- },
277
- "5": {
278
- "name": "constant.language.external.d"
279
- },
280
- "7": {
281
- "name": "constant.language.external.d"
265
+ "patterns": [
266
+ {
267
+ "include": "#meta-external"
268
+ }
269
+ ]
282
270
  }
283
271
  },
284
- "match": "\\b(extern)\\b(\\s*\\(\\s*(((C\\+\\+)(\\s*,\\s*[A-Za-z_][A-Za-z0-9._]*)?)|(C|D|Windows|Pascal|System))\\s*\\))?",
272
+ "match": "(\\b(?:extern)\\b(?:\\s*\\(\\s*(?:(?:(?:C\\+\\+)(?:\\s*,\\s*[A-Za-z_][A-Za-z0-9._]*)?)|\\b(?:C|D|Windows|Pascal|System|Objective-C)\\b)\\s*\\))?)",
285
273
  "name": "meta.external.d"
286
274
  },
287
275
  {
@@ -523,6 +511,34 @@
523
511
  "match": "(?i:%(\\([a-z_]+\\))?#?0?\\-?[ ]?\\+?([0-9]*|\\*)(\\.([0-9]*|\\*))?[hL]?[a-z%])",
524
512
  "name": "constant.other.placeholder.d"
525
513
  },
514
+ "meta-external": {
515
+ "captures": {
516
+ "identifier": {
517
+ "name": "constant.language.external.d"
518
+ },
519
+ "keyword": {
520
+ "name": "keyword.other.external.d"
521
+ }
522
+ },
523
+ "match": "\\b(?<keyword>extern)\\b(\\s*\\(\\s*(?:(?:(?<identifier>C\\+\\+)(?:\\s*,\\s*[A-Za-z_][A-Za-z0-9._]*)?)|(?<identifier>C|D|Windows|Pascal|System|Objective-C))\\s*\\))?",
524
+ "name": "meta.external.d"
525
+ },
526
+ "meta-modifier": {
527
+ "captures": {
528
+ "meta_external": {
529
+ "patterns": [
530
+ {
531
+ "include": "#meta-external"
532
+ }
533
+ ]
534
+ },
535
+ "modifier": {
536
+ "name": "storage.modifier.d"
537
+ }
538
+ },
539
+ "match": "(?x)\n\t\t\t\t(?:\n\t\t\t\t\t(?<modifier>\\b(?:public|private|protected|static|final|synchronized|abstract|export|shared)\\b) |\n\t\t\t\t\t(?<meta_external>\\b(?:extern)\\b(?:\\s*\\(\\s*(?:(?:(?:C\\+\\+)(?:\\s*,\\s*[A-Za-z_][A-Za-z0-9._]*)?)|\\b(?:C|D|Windows|Pascal|System|Objective-C)\\b)\\s*\\))?)\n\t\t\t\t)\\s*\n\t\t\t",
540
+ "name": "meta.modifier.d"
541
+ },
526
542
  "regular_expressions": {
527
543
  "comment": "Change disabled to 1 to turn off syntax highlighting in “r” strings.",
528
544
  "disabled": 1,
@@ -5,154 +5,297 @@
5
5
  "gn",
6
6
  "gni"
7
7
  ],
8
- "injections": {
9
- "source.gn": {
10
- "patterns": [
11
- {
12
- "include": "#comment"
13
- }
14
- ]
15
- }
16
- },
8
+ "firstLineMatch": "(?xi)\n# Emacs modeline\n-\\*-(?:\\s*(?=[^:;\\s]+\\s*-\\*-)|(?:.*?[;\\s]|(?<=-\\*-))mode\\s*:\\s*)\n gn\n(?=[\\s;]|(?<![-*])-\\*-).*?-\\*-\n|\n# Vim modeline\n(?:(?:\\s|^)vi(?:m[<=>]?\\d+|m)?|\\sex)(?=:(?=\\s*set?\\s[^\\n:]+:)|:(?!\\s*set?\\s))(?:(?:\\s|\\s*:\\s*)\\w*(?:\\s*=(?:[^\\n\\\\\\s]|\\\\.)*)?)*[\\s:](?:filetype|ft|syntax)\\s*=\n gn\n(?=\\s|:|$)",
17
9
  "patterns": [
18
10
  {
19
- "include": "#assignment"
20
- },
21
- {
22
- "include": "#function"
11
+ "include": "#main"
23
12
  }
24
13
  ],
25
14
  "repository": {
26
- "comment": {
27
- "name": "punctuation.comment.gn",
28
- "match": "#[^\\n]*\\n"
15
+ "main": {
16
+ "patterns": [
17
+ {
18
+ "include": "#comment"
19
+ },
20
+ {
21
+ "include": "#number"
22
+ },
23
+ {
24
+ "include": "#condition"
25
+ },
26
+ {
27
+ "include": "#function-call"
28
+ },
29
+ {
30
+ "include": "#keywords"
31
+ },
32
+ {
33
+ "include": "#string"
34
+ },
35
+ {
36
+ "include": "#variable"
37
+ },
38
+ {
39
+ "include": "#operators"
40
+ },
41
+ {
42
+ "include": "#array"
43
+ },
44
+ {
45
+ "include": "#brackets"
46
+ },
47
+ {
48
+ "include": "#separators"
49
+ },
50
+ {
51
+ "include": "#scope"
52
+ }
53
+ ]
29
54
  },
30
- "string": {
55
+ "separators": {
31
56
  "patterns": [
32
57
  {
33
- "begin": "\"\"\"",
34
- "end": "\"\"\"",
35
- "name": "string.quoted.triple.gn"
58
+ "name": "punctuation.separator.list.comma.gn",
59
+ "match": ","
36
60
  },
37
61
  {
38
- "match": "(')([^']*)(')",
62
+ "name": "punctuation.delimiter.property.period.gn",
63
+ "match": "\\."
64
+ }
65
+ ]
66
+ },
67
+ "comment": {
68
+ "name": "comment.line.number-sign.gn",
69
+ "begin": "#",
70
+ "end": "$",
71
+ "beginCaptures": {
72
+ "0": {
73
+ "name": "punctuation.definition.comment.gn"
74
+ }
75
+ },
76
+ "patterns": [
77
+ {
78
+ "match": "(?<=TODO)(\\()\\s*(\\w+)\\s*(\\))\\s*:",
39
79
  "captures": {
40
- "0": {
41
- "name": "punctuation.string.single.begin.gn"
42
- },
43
80
  "1": {
44
- "name": "string.quoted.single.gn"
81
+ "name": "punctuation.section.begin.bracket.round.todo"
45
82
  },
46
83
  "2": {
47
- "name": "punctuation.string.single.end.gn"
84
+ "name": "storage.type.class.assignee.todo"
85
+ },
86
+ "3": {
87
+ "name": "punctuation.section.end.bracket.round.todo"
48
88
  }
49
89
  }
50
- },
90
+ }
91
+ ]
92
+ },
93
+ "condition": {
94
+ "name": "meta.condition.gn",
95
+ "begin": "(if|else)\\s*(?=\\()",
96
+ "beginCaptures": {
97
+ "1": {
98
+ "name": "keyword.control.$1.gn"
99
+ }
100
+ },
101
+ "end": "(?<=\\))",
102
+ "patterns": [
51
103
  {
52
- "match": "(\")([^\"]*)(\")",
53
- "captures": {
104
+ "begin": "\\G\\(",
105
+ "beginCaptures": {
54
106
  "0": {
55
- "name": "punctuation.string.double.begin.gn"
56
- },
57
- "1": {
58
- "name": "string.quoted.double.gn"
107
+ "name": "punctuation.definition.condition.begin.bracket.round.gn"
108
+ }
109
+ },
110
+ "end": "\\)",
111
+ "endCaptures": {
112
+ "0": {
113
+ "name": "punctuation.definition.condition.end.bracket.round.gn"
114
+ }
115
+ },
116
+ "patterns": [
117
+ {
118
+ "include": "$self"
59
119
  },
60
- "2": {
61
- "name": "punctuation.string.double.end.gn"
120
+ {
121
+ "match": "\\w+",
122
+ "name": "variable.reference.gn"
62
123
  }
63
- }
124
+ ]
64
125
  }
65
126
  ]
66
127
  },
67
- "number": {
68
- "match": "\\d+",
69
- "captures": {
70
- "0": {
71
- "name": "constant.numeric.gn"
72
- }
73
- }
74
- },
75
- "variable": {
76
- "match": "\\w+",
77
- "captures": {
78
- "0": {
79
- "name": "variable.other.gn"
128
+ "keywords": {
129
+ "patterns": [
130
+ {
131
+ "name": "constant.language.boolean.$1.gn",
132
+ "match": "\\b(true|false)\\b"
133
+ },
134
+ {
135
+ "name": "keyword.control.$1.gn",
136
+ "match": "\\b(if|else|foreach)\\b"
80
137
  }
81
- }
138
+ ]
82
139
  },
83
- "function": {
84
- "name": "meta.function.gn",
85
- "begin": "(\\w+)\\s*(\\()",
140
+ "string": {
141
+ "name": "string.quoted.double.gn",
142
+ "begin": "\"",
143
+ "end": "\"",
86
144
  "beginCaptures": {
87
- "1": {
88
- "name": "storage.type.function.gn"
89
- },
90
- "2": {
91
- "name": "punctuation.function.parameters.begin.gn"
145
+ "0": {
146
+ "name": "punctuation.definition.string.begin.gn"
92
147
  }
93
148
  },
94
- "end": "\\)",
95
149
  "endCaptures": {
96
150
  "0": {
97
- "name": "punctuation.function.parameters.end.gn"
151
+ "name": "punctuation.definition.string.end.gn"
98
152
  }
99
153
  },
100
154
  "patterns": [
101
155
  {
102
- "include": "#argument"
156
+ "name": "constant.character.escape.gn",
157
+ "match": "\\\\[\"$\\\\]"
158
+ },
159
+ {
160
+ "name": "constant.character.escape.hex.gn",
161
+ "match": "\\$0x[0-9A-Fa-f]{2}"
162
+ },
163
+ {
164
+ "name": "punctuation.separator.build-path.gn",
165
+ "match": ":(?=\\w+\")"
166
+ },
167
+ {
168
+ "name": "punctuation.definition.build-path.gn",
169
+ "match": "\\G//"
170
+ },
171
+ {
172
+ "name": "source.gn.embedded",
173
+ "begin": "\\${",
174
+ "end": "}",
175
+ "contentName": "variable.interpolated.embedded.gn",
176
+ "beginCaptures": {
177
+ "0": {
178
+ "name": "punctuation.section.embedded.begin.gn"
179
+ }
180
+ },
181
+ "endCaptures": {
182
+ "0": {
183
+ "name": "punctuation.section.embedded.end.gn"
184
+ }
185
+ }
186
+ },
187
+ {
188
+ "name": "variable.interpolated.embedded.gn",
189
+ "match": "(\\$)\\w+",
190
+ "captures": {
191
+ "1": {
192
+ "name": "punctuation.definition.variable.embedded.gn"
193
+ }
194
+ }
103
195
  }
104
196
  ]
105
197
  },
106
- "argument": {
198
+ "number": {
107
199
  "patterns": [
108
200
  {
109
- "name": "mata.argument.gn",
110
- "begin": "(\\w+)\\s*(=)\\s*",
111
- "beginCaptures": {
201
+ "name": "invalid.illegal.number.gn",
202
+ "match": "-0+|0+(?=[1-9])"
203
+ },
204
+ {
205
+ "name": "constant.numeric.gn",
206
+ "match": "-?\\d+"
207
+ }
208
+ ]
209
+ },
210
+ "variable": {
211
+ "patterns": [
212
+ {
213
+ "name": "variable.assignment.gn",
214
+ "match": "\\w+(?=\\s*[-+]?=|\\s*[\\[.])"
215
+ },
216
+ {
217
+ "match": "(?<==)\\s*(?!\\d|if|else|foreach|true|false)(\\w+)\\s*(?!\\()",
218
+ "captures": {
112
219
  "1": {
113
- "name": "variable.parameter.gn"
114
- },
115
- "2": {
116
- "name": "keyword.operator.assignment.gn"
220
+ "name": "variable.reference.gn"
221
+ }
222
+ }
223
+ }
224
+ ]
225
+ },
226
+ "function-call": {
227
+ "name": "meta.function-call.gn",
228
+ "begin": "\\s*(?!if|else|foreach|true|false)(\\w+)\\s*(?=\\()",
229
+ "beginCaptures": {
230
+ "1": {
231
+ "name": "entity.name.function.gn"
232
+ }
233
+ },
234
+ "end": "(?<=\\))",
235
+ "patterns": [
236
+ {
237
+ "name": "meta.parameters.gn",
238
+ "begin": "\\G\\(",
239
+ "beginCaptures": {
240
+ "0": {
241
+ "name": "punctuation.definition.parameters.begin.bracket.round.gn"
117
242
  }
118
243
  },
119
- "end": ",|\\n",
244
+ "end": "\\)",
120
245
  "endCaptures": {
121
246
  "0": {
122
- "name": "punctuation.separator.gn"
247
+ "name": "punctuation.definition.parameters.end.bracket.round.gn"
123
248
  }
124
249
  },
125
250
  "patterns": [
126
251
  {
127
- "include": "#expression"
252
+ "include": "$self"
253
+ },
254
+ {
255
+ "match": "\\w+",
256
+ "name": "variable.argument.parameter.gn"
128
257
  }
129
258
  ]
259
+ }
260
+ ]
261
+ },
262
+ "operators": {
263
+ "patterns": [
264
+ {
265
+ "name": "keyword.operator.comparison.gn",
266
+ "match": "==|!=|[><]=?"
267
+ },
268
+ {
269
+ "name": "keyword.operator.logical.gn",
270
+ "match": "!|[|&]{2}"
130
271
  },
131
272
  {
132
- "include": "#expression"
273
+ "name": "keyword.operator.assignment.gn",
274
+ "match": "[-+]?="
275
+ },
276
+ {
277
+ "name": "keyword.operator.arithmetic.gn",
278
+ "match": "-|\\+"
133
279
  }
134
280
  ]
135
281
  },
136
- "assignment": {
137
- "name": "meta.assignment.gn",
138
- "begin": "(\\w+)\\s*(=)\\s*",
282
+ "scope": {
283
+ "name": "meta.scope.gn",
284
+ "begin": "{",
285
+ "end": "}",
139
286
  "beginCaptures": {
140
- "1": {
141
- "name": "variable.other.gn"
142
- },
143
- "2": {
144
- "name": "keyword.operator.assignment.gn"
287
+ "0": {
288
+ "name": "punctuation.scope.begin.bracket.curly.gn"
145
289
  }
146
290
  },
147
- "end": "(;|\\n)",
148
291
  "endCaptures": {
149
292
  "0": {
150
- "name": "punctuation.statement.end.gn"
293
+ "name": "punctuation.scope.begin.bracket.curly.gn"
151
294
  }
152
295
  },
153
296
  "patterns": [
154
297
  {
155
- "include": "#expression"
298
+ "include": "$self"
156
299
  }
157
300
  ]
158
301
  },
@@ -161,86 +304,45 @@
161
304
  "begin": "\\[",
162
305
  "beginCaptures": {
163
306
  "0": {
164
- "name": "punctuation.array.begin.gn"
307
+ "name": "punctuation.section.begin.bracket.square.gn"
165
308
  }
166
309
  },
167
310
  "end": "\\]",
168
311
  "endCaptures": {
169
312
  "0": {
170
- "name": "punctuation.array.end.gn"
313
+ "name": "punctuation.section.end.bracket.square.gn"
171
314
  }
172
315
  },
173
316
  "patterns": [
174
317
  {
175
- "include": "#expression"
318
+ "include": "$self"
176
319
  },
177
320
  {
178
- "match": "\\s*([,])\\s*",
179
- "captures": {
180
- "1": {
181
- "name": "punctuation.separator.gn"
182
- }
183
- }
321
+ "match": "\\w+",
322
+ "name": "variable.reference.gn"
184
323
  }
185
324
  ]
186
325
  },
187
- "dictionary": {
188
- "name": "meta.dictionary.gn",
189
- "begin": "\\{",
326
+ "brackets": {
327
+ "begin": "\\(",
190
328
  "beginCaptures": {
191
329
  "0": {
192
- "name": "punctuation.dictionary.begin.gn"
330
+ "name": "punctuation.section.begin.bracket.round.gn"
193
331
  }
194
332
  },
195
- "end": "\\s*\\}",
333
+ "end": "\\)",
196
334
  "endCaptures": {
197
335
  "0": {
198
- "name": "punctuation.dictionary.end.gn"
336
+ "name": "punctuation.section.end.bracket.round.gn"
199
337
  }
200
338
  },
201
339
  "patterns": [
202
340
  {
203
- "include": "#expression"
204
- },
205
- {
206
- "match": "\\s*([,:])\\s*",
207
- "captures": {
208
- "1": {
209
- "name": "punctuation.separator.gn"
210
- }
211
- }
212
- }
213
- ]
214
- },
215
- "expression": {
216
- "name": "meta.expression.gn",
217
- "contentName": "meta.expression.gn",
218
- "patterns": [
219
- {
220
- "include": "#function"
221
- },
222
- {
223
- "include": "#array"
224
- },
225
- {
226
- "include": "#dictionary"
227
- },
228
- {
229
- "include": "#number"
230
- },
231
- {
232
- "include": "#variable"
233
- },
234
- {
235
- "include": "#string"
341
+ "include": "$self"
236
342
  },
237
343
  {
238
- "match": "\\+|\\-|\\%",
239
- "captures": {
240
- "0": {
241
- "name": "operator.gn"
242
- }
243
- }
344
+ "match": "\\w+",
345
+ "name": "variable.reference.gn"
244
346
  }
245
347
  ]
246
348
  }