github-linguist 5.0.6 → 5.0.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/grammars/source.bsl.json +196 -162
  3. data/grammars/source.ceylon.json +43 -21
  4. data/grammars/source.coffee.json +46 -21
  5. data/grammars/source.cs.json +2 -2
  6. data/grammars/source.csound-score.json +41 -18
  7. data/grammars/source.csound.json +63 -7
  8. data/grammars/source.css.json +2 -2
  9. data/grammars/source.css.less.json +22 -91
  10. data/grammars/source.ditroff.json +114 -116
  11. data/grammars/source.gfm.clean.json +28 -0
  12. data/grammars/source.gfm.json +1 -0
  13. data/grammars/source.jison.json +678 -0
  14. data/grammars/source.jisonlex-injection.json +11 -0
  15. data/grammars/source.jisonlex.json +432 -0
  16. data/grammars/source.js.json +12 -67
  17. data/grammars/source.jsdoc.json +485 -0
  18. data/grammars/source.p4.json +15 -0
  19. data/grammars/source.perl6fe.json +37 -1
  20. data/grammars/source.puppet.json +1 -1
  21. data/grammars/source.python.json +6 -3
  22. data/grammars/source.quoting.perl6fe.json +101 -0
  23. data/grammars/source.rpm-spec.json +7 -3
  24. data/grammars/source.scad.json +152 -0
  25. data/grammars/source.shaderlab.json +42 -15
  26. data/grammars/source.terraform.json +18 -0
  27. data/grammars/source.yaml.json +57 -32
  28. data/grammars/text.html.php.blade.json +1 -1
  29. data/grammars/text.marko.json +1522 -0
  30. data/grammars/text.roff.json +9 -6
  31. data/lib/linguist.rb +2 -2
  32. data/lib/linguist/documentation.yml +4 -3
  33. data/lib/linguist/heuristics.rb +2 -0
  34. data/lib/linguist/languages.json +1 -1
  35. data/lib/linguist/languages.yml +33 -1
  36. data/lib/linguist/samples.json +423 -48
  37. data/lib/linguist/version.rb +1 -1
  38. metadata +13 -7
  39. data/grammars/module.ceylon.json +0 -54
@@ -181,144 +181,142 @@
181
181
  }
182
182
  },
183
183
  "deviceControl": {
184
- "name": "meta.device-control.ditroff",
185
- "begin": "^\\s*(x)\\s*",
186
- "end": "(?=$|#)",
187
- "beginCaptures": {
188
- "1": {
189
- "name": "keyword.operator.other.ditroff"
190
- }
191
- },
192
184
  "patterns": [
193
185
  {
194
- "name": "keyword.device.control.ditroff",
195
- "match": "\\G([ipst]\\S*)\\s*?(?=$|#)"
196
- },
197
- {
198
- "name": "meta.space-underlining.gnu.ditroff",
199
- "match": "\\G(u\\S*)\\s+(?:(1|0)|(\\d+))\\s*?(?=$|#)",
200
- "captures": {
186
+ "name": "meta.custom.device-control.ditroff",
187
+ "begin": "^\\s*(x)\\s*(X\\S*)",
188
+ "end": "^(?!\\+)",
189
+ "beginCaptures": {
201
190
  "1": {
202
- "name": "keyword.device.control.ditroff"
191
+ "name": "keyword.operator.other.ditroff"
203
192
  },
204
193
  "2": {
205
- "name": "constant.numeric.integer.ditroff"
206
- },
207
- "3": {
208
- "name": "invalid.illegal.argument.ditroff"
209
- }
210
- }
211
- },
212
- {
213
- "name": "meta.source-filename.gnu.ditroff",
214
- "match": "\\G(F\\S*)\\s+(\\S+)\\s*?(?=$|#)",
215
- "captures": {
216
- "1": {
217
194
  "name": "keyword.device.control.ditroff"
218
- },
219
- "2": {
220
- "name": "variable.parameter.filename.ditroff"
221
195
  }
222
- }
196
+ },
197
+ "contentName": "string.raw.unquoted.heredoc.ditroff",
198
+ "patterns": [
199
+ {
200
+ "name": "keyword.operator.line-continuation.gnu.ditroff",
201
+ "match": "^\\+"
202
+ }
203
+ ]
223
204
  },
224
205
  {
225
- "name": "meta.typesetter-device.ditroff",
226
- "match": "\\G(T\\S*)\\s+((\\S+))",
227
- "captures": {
206
+ "name": "meta.device-control.ditroff",
207
+ "begin": "^\\s*(x)\\s*",
208
+ "end": "(?=$|#)",
209
+ "beginCaptures": {
228
210
  "1": {
229
- "name": "keyword.device.control.ditroff"
211
+ "name": "keyword.operator.other.ditroff"
212
+ }
213
+ },
214
+ "patterns": [
215
+ {
216
+ "name": "keyword.device.control.ditroff",
217
+ "match": "\\G([ipst]\\S*)\\s*?(?=$|#)"
230
218
  },
231
- "2": {
232
- "name": "variable.parameter.ditroff"
219
+ {
220
+ "name": "meta.space-underlining.gnu.ditroff",
221
+ "match": "\\G(u\\S*)\\s+(?:(1|0)|(\\d+))\\s*?(?=$|#)",
222
+ "captures": {
223
+ "1": {
224
+ "name": "keyword.device.control.ditroff"
225
+ },
226
+ "2": {
227
+ "name": "constant.numeric.integer.ditroff"
228
+ },
229
+ "3": {
230
+ "name": "invalid.illegal.argument.ditroff"
231
+ }
232
+ }
233
233
  },
234
- "3": {
235
- "patterns": [
236
- {
237
- "name": "support.constant.device-name.ditroff",
238
- "match": "(?<=\\s|^)(?:dvi|html|lbp|lj4|ps|pdf|ascii|cp1047|latin1|utf8|X75|X75-12|X100|X100-12)(?=\\s|$)"
234
+ {
235
+ "name": "meta.source-filename.gnu.ditroff",
236
+ "match": "\\G(F\\S*)\\s+(\\S+)\\s*?(?=$|#)",
237
+ "captures": {
238
+ "1": {
239
+ "name": "keyword.device.control.ditroff"
240
+ },
241
+ "2": {
242
+ "name": "variable.parameter.filename.ditroff"
239
243
  }
240
- ]
241
- }
242
- }
243
- },
244
- {
245
- "name": "meta.device-resolution.ditroff",
246
- "match": "\\G(r\\S*)((?:\\s+(\\d+)){1,3})\\s*?(?=$|#)",
247
- "captures": {
248
- "1": {
249
- "name": "keyword.device.control.ditroff"
244
+ }
250
245
  },
251
- "2": {
252
- "patterns": [
253
- {
254
- "include": "text.roff#number"
246
+ {
247
+ "name": "meta.typesetter-device.ditroff",
248
+ "match": "\\G(T\\S*)\\s+((\\S+))",
249
+ "captures": {
250
+ "1": {
251
+ "name": "keyword.device.control.ditroff"
252
+ },
253
+ "2": {
254
+ "name": "variable.parameter.ditroff"
255
+ },
256
+ "3": {
257
+ "patterns": [
258
+ {
259
+ "name": "support.constant.device-name.ditroff",
260
+ "match": "(?<=\\s|^)(?:dvi|html|lbp|lj4|ps|pdf|ascii|cp1047|latin1|utf8|X75|X75-12|X100|X100-12)(?=\\s|$)"
261
+ }
262
+ ]
255
263
  }
256
- ]
257
- }
258
- }
259
- },
260
- {
261
- "name": "meta.mount-font.ditroff",
262
- "match": "\\G(f\\S*)(?:\\s+(\\d+))?(?:\\s+([-\\w]+))?\\s*?(?=$|#)",
263
- "captures": {
264
- "1": {
265
- "name": "keyword.device.control.ditroff"
264
+ }
266
265
  },
267
- "2": {
268
- "name": "constant.numeric.integer.ditroff"
266
+ {
267
+ "name": "meta.device-resolution.ditroff",
268
+ "match": "\\G(r\\S*)((?:\\s+(\\d+)){1,3})\\s*?(?=$|#)",
269
+ "captures": {
270
+ "1": {
271
+ "name": "keyword.device.control.ditroff"
272
+ },
273
+ "2": {
274
+ "patterns": [
275
+ {
276
+ "include": "text.roff#number"
277
+ }
278
+ ]
279
+ }
280
+ }
269
281
  },
270
- "3": {
271
- "name": "variable.parameter.ditroff"
272
- }
273
- }
274
- },
275
- {
276
- "name": "meta.set-character-property.ditroff",
277
- "match": "\\G([HS]\\S*)(?:\\s+(\\d+))?\\s*?(?=$|#)",
278
- "captures": {
279
- "1": {
280
- "name": "keyword.device.control.ditroff"
282
+ {
283
+ "name": "meta.mount-font.ditroff",
284
+ "match": "\\G(f\\S*)(?:\\s+(\\d+))?(?:\\s+([-\\w]+))?\\s*?(?=$|#)",
285
+ "captures": {
286
+ "1": {
287
+ "name": "keyword.device.control.ditroff"
288
+ },
289
+ "2": {
290
+ "name": "constant.numeric.integer.ditroff"
291
+ },
292
+ "3": {
293
+ "name": "variable.parameter.ditroff"
294
+ }
295
+ }
281
296
  },
282
- "2": {
283
- "name": "constant.numeric.ditroff"
284
- }
285
- }
286
- },
287
- {
288
- "name": "meta.x-escape.custom-control.ditroff",
289
- "begin": "\\G(X\\S*)",
290
- "end": "^(?!\\+)(.*)",
291
- "beginCaptures": {
292
- "1": {
293
- "name": "keyword.device.control.ditroff"
294
- }
295
- },
296
- "endCaptures": {
297
- "1": {
298
- "patterns": [
299
- {
300
- "include": "#main"
297
+ {
298
+ "name": "meta.set-character-property.ditroff",
299
+ "match": "\\G([HS]\\S*)(?:\\s+(\\d+))?\\s*?(?=$|#)",
300
+ "captures": {
301
+ "1": {
302
+ "name": "keyword.device.control.ditroff"
303
+ },
304
+ "2": {
305
+ "name": "constant.numeric.ditroff"
301
306
  }
302
- ]
303
- }
304
- },
305
- "contentName": "string.raw.unquoted.heredoc.ditroff",
306
- "patterns": [
307
+ }
308
+ },
307
309
  {
308
- "name": "keyword.operator.line-continuation.gnu.ditroff",
309
- "match": "^\\+"
310
+ "name": "meta.unknown-command.ditroff",
311
+ "begin": "\\G(\\S+)",
312
+ "end": "(?=$|#)",
313
+ "beginCaptures": {
314
+ "1": {
315
+ "name": "keyword.device.control.ditroff"
316
+ }
317
+ }
310
318
  }
311
319
  ]
312
- },
313
- {
314
- "name": "meta.unknown-command.ditroff",
315
- "begin": "\\G(\\S+)",
316
- "end": "(?=$|#)",
317
- "beginCaptures": {
318
- "1": {
319
- "name": "keyword.device.control.ditroff"
320
- }
321
- }
322
320
  }
323
321
  ]
324
322
  },
@@ -0,0 +1,28 @@
1
+ {
2
+ "name": "Literate Clean",
3
+ "scopeName": "source.gfm.clean",
4
+ "fileTypes": [
5
+ "lcl"
6
+ ],
7
+ "firstLineMatch": "^[><] module",
8
+ "patterns": [
9
+ {
10
+ "name": "meta.embedded.clean",
11
+ "begin": "^([><] )",
12
+ "end": "$",
13
+ "captures": {
14
+ "1": {
15
+ "name": "support.quote.gfm"
16
+ }
17
+ },
18
+ "patterns": [
19
+ {
20
+ "include": "source.clean"
21
+ }
22
+ ]
23
+ },
24
+ {
25
+ "include": "source.gfm"
26
+ }
27
+ ]
28
+ }
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "GitHub Markdown",
3
3
  "scopeName": "source.gfm",
4
+ "limitLineLength": false,
4
5
  "fileTypes": [
5
6
  "markdown",
6
7
  "md",
@@ -0,0 +1,678 @@
1
+ {
2
+ "name": "Jison",
3
+ "scopeName": "source.jison",
4
+ "fileTypes": [
5
+ "jison"
6
+ ],
7
+ "patterns": [
8
+ {
9
+ "begin": "%%",
10
+ "beginCaptures": {
11
+ "0": {
12
+ "name": "meta.separator.section.jison"
13
+ }
14
+ },
15
+ "patterns": [
16
+ {
17
+ "begin": "%%",
18
+ "beginCaptures": {
19
+ "0": {
20
+ "name": "meta.separator.section.jison"
21
+ }
22
+ },
23
+ "patterns": [
24
+ {
25
+ "name": "meta.section.epilogue.jison",
26
+ "begin": "\\G",
27
+ "patterns": [
28
+ {
29
+ "include": "#epilogue_section"
30
+ }
31
+ ]
32
+ }
33
+ ]
34
+ },
35
+ {
36
+ "name": "meta.section.rules.jison",
37
+ "begin": "(?!%%)",
38
+ "end": "(?=%%)",
39
+ "patterns": [
40
+ {
41
+ "include": "#rules_section"
42
+ }
43
+ ]
44
+ }
45
+ ]
46
+ },
47
+ {
48
+ "name": "meta.section.declarations.jison",
49
+ "begin": "(?!%%)",
50
+ "end": "(?=%%)",
51
+ "patterns": [
52
+ {
53
+ "include": "#declarations_section"
54
+ }
55
+ ]
56
+ }
57
+ ],
58
+ "repository": {
59
+ "declarations_section": {
60
+ "patterns": [
61
+ {
62
+ "include": "#comments"
63
+ },
64
+ {
65
+ "begin": "^\\s*(%lex)\\s*$",
66
+ "end": "^\\s*(/lex)\\b",
67
+ "beginCaptures": {
68
+ "1": {
69
+ "name": "entity.name.tag.lexer.begin.jison"
70
+ }
71
+ },
72
+ "endCaptures": {
73
+ "1": {
74
+ "name": "entity.name.tag.lexer.end.jison"
75
+ }
76
+ },
77
+ "patterns": [
78
+ {
79
+ "begin": "%%",
80
+ "end": "(?=/lex)",
81
+ "beginCaptures": {
82
+ "0": {
83
+ "name": "meta.separator.section.jisonlex"
84
+ }
85
+ },
86
+ "patterns": [
87
+ {
88
+ "begin": "^%%",
89
+ "end": "(?=/lex)",
90
+ "beginCaptures": {
91
+ "0": {
92
+ "name": "meta.separator.section.jisonlex"
93
+ }
94
+ },
95
+ "patterns": [
96
+ {
97
+ "name": "meta.section.user-code.jisonlex",
98
+ "begin": "(?!%%)",
99
+ "end": "(?=/lex)",
100
+ "patterns": [
101
+ {
102
+ "include": "source.jisonlex#user_code_section"
103
+ }
104
+ ]
105
+ }
106
+ ]
107
+ },
108
+ {
109
+ "name": "meta.section.rules.jisonlex",
110
+ "begin": "(?!%%)",
111
+ "end": "(?=^(?:%%|/lex))",
112
+ "patterns": [
113
+ {
114
+ "include": "source.jisonlex#rules_section"
115
+ }
116
+ ]
117
+ }
118
+ ]
119
+ },
120
+ {
121
+ "name": "meta.section.definitions.jisonlex",
122
+ "begin": "(?!%%)",
123
+ "end": "(?=%%|/lex)",
124
+ "patterns": [
125
+ {
126
+ "include": "source.jisonlex#definitions_section"
127
+ }
128
+ ]
129
+ }
130
+ ]
131
+ },
132
+ {
133
+ "name": "meta.section.prologue.jison",
134
+ "begin": "(?=%\\{)",
135
+ "end": "(?<=%\\})",
136
+ "patterns": [
137
+ {
138
+ "include": "#user_code_blocks"
139
+ }
140
+ ]
141
+ },
142
+ {
143
+ "include": "#options_declarations"
144
+ },
145
+ {
146
+ "name": "keyword.other.declaration.$1.jison",
147
+ "match": "%(ebnf|left|nonassoc|parse-param|right|start)\\b"
148
+ },
149
+ {
150
+ "include": "#include_declarations"
151
+ },
152
+ {
153
+ "name": "meta.code.jison",
154
+ "begin": "%(code)\\b",
155
+ "end": "$",
156
+ "beginCaptures": {
157
+ "0": {
158
+ "name": "keyword.other.declaration.$1.jison"
159
+ }
160
+ },
161
+ "patterns": [
162
+ {
163
+ "include": "#comments"
164
+ },
165
+ {
166
+ "include": "#rule_actions"
167
+ },
168
+ {
169
+ "name": "keyword.other.code-qualifier.$1.jison",
170
+ "match": "(init|required)"
171
+ },
172
+ {
173
+ "include": "#quoted_strings"
174
+ },
175
+ {
176
+ "name": "string.unquoted.jison",
177
+ "match": "\\b[\\p{Alpha}_](?:[\\w-]*\\w)?\\b"
178
+ }
179
+ ]
180
+ },
181
+ {
182
+ "name": "meta.token.jison",
183
+ "begin": "%(token)\\b",
184
+ "end": "$|(%%|;)",
185
+ "beginCaptures": {
186
+ "0": {
187
+ "name": "keyword.other.declaration.$1.jison"
188
+ }
189
+ },
190
+ "endCaptures": {
191
+ "1": {
192
+ "name": "punctuation.terminator.declaration.token.jison"
193
+ }
194
+ },
195
+ "patterns": [
196
+ {
197
+ "include": "#comments"
198
+ },
199
+ {
200
+ "include": "#numbers"
201
+ },
202
+ {
203
+ "include": "#quoted_strings"
204
+ },
205
+ {
206
+ "name": "invalid.unimplemented.jison",
207
+ "match": "<[\\p{Alpha}_](?:[\\w-]*\\w)?>"
208
+ },
209
+ {
210
+ "name": "entity.other.token.jison",
211
+ "match": "\\S+"
212
+ }
213
+ ]
214
+ },
215
+ {
216
+ "name": "keyword.other.declaration.$1.jison",
217
+ "match": "%(debug|import|parser-type)\\b"
218
+ },
219
+ {
220
+ "name": "invalid.illegal.jison",
221
+ "match": "%prec\\b"
222
+ },
223
+ {
224
+ "name": "invalid.unimplemented.jison",
225
+ "match": "%[\\p{Alpha}_](?:[\\w-]*\\w)?\\b"
226
+ },
227
+ {
228
+ "include": "#numbers"
229
+ },
230
+ {
231
+ "include": "#quoted_strings"
232
+ }
233
+ ]
234
+ },
235
+ "rules_section": {
236
+ "patterns": [
237
+ {
238
+ "include": "#comments"
239
+ },
240
+ {
241
+ "include": "#actions"
242
+ },
243
+ {
244
+ "include": "#include_declarations"
245
+ },
246
+ {
247
+ "name": "meta.rule.jison",
248
+ "begin": "\\b[\\p{Alpha}_](?:[\\w-]*\\w)?\\b",
249
+ "end": ";",
250
+ "beginCaptures": {
251
+ "0": {
252
+ "name": "entity.name.constant.rule-result.jison"
253
+ }
254
+ },
255
+ "endCaptures": {
256
+ "0": {
257
+ "name": "punctuation.terminator.rule.jison"
258
+ }
259
+ },
260
+ "patterns": [
261
+ {
262
+ "include": "#comments"
263
+ },
264
+ {
265
+ "name": "meta.rule-components.jison",
266
+ "begin": ":",
267
+ "end": "(?=;)",
268
+ "beginCaptures": {
269
+ "0": {
270
+ "name": "keyword.operator.rule-components.assignment.jison"
271
+ }
272
+ },
273
+ "patterns": [
274
+ {
275
+ "include": "#comments"
276
+ },
277
+ {
278
+ "include": "#quoted_strings"
279
+ },
280
+ {
281
+ "match": "(\\[)([\\p{Alpha}_](?:[\\w-]*\\w)?)(\\])",
282
+ "captures": {
283
+ "1": {
284
+ "name": "punctuation.definition.named-reference.begin.jison"
285
+ },
286
+ "2": {
287
+ "name": "entity.name.other.reference.jison"
288
+ },
289
+ "3": {
290
+ "name": "punctuation.definition.named-reference.end.jison"
291
+ }
292
+ }
293
+ },
294
+ {
295
+ "name": "meta.prec.jison",
296
+ "begin": "(%(prec))\\s*",
297
+ "end": "(?<=['\"])|(?=\\s)",
298
+ "beginCaptures": {
299
+ "1": {
300
+ "name": "keyword.other.$2.jison"
301
+ }
302
+ },
303
+ "patterns": [
304
+ {
305
+ "include": "#comments"
306
+ },
307
+ {
308
+ "include": "#quoted_strings"
309
+ },
310
+ {
311
+ "name": "constant.other.token.jison",
312
+ "begin": "(?=\\S)",
313
+ "end": "(?=\\s)"
314
+ }
315
+ ]
316
+ },
317
+ {
318
+ "name": "keyword.operator.rule-components.separator.jison",
319
+ "match": "\\|"
320
+ },
321
+ {
322
+ "name": "keyword.other.$0.jison",
323
+ "match": "\\berror\\b"
324
+ },
325
+ {
326
+ "name": "keyword.other.empty.jison",
327
+ "match": "(?:%(?:e(?:mpty|psilon))|\\b[Ɛɛεϵ])\\b"
328
+ },
329
+ {
330
+ "include": "#rule_actions"
331
+ }
332
+ ]
333
+ }
334
+ ]
335
+ }
336
+ ]
337
+ },
338
+ "epilogue_section": {
339
+ "patterns": [
340
+ {
341
+ "include": "#user_code_include_declarations"
342
+ },
343
+ {
344
+ "include": "source.js"
345
+ }
346
+ ]
347
+ },
348
+ "actions": {
349
+ "patterns": [
350
+ {
351
+ "name": "meta.action.jison",
352
+ "begin": "\\{\\{",
353
+ "end": "\\}\\}",
354
+ "beginCaptures": {
355
+ "0": {
356
+ "name": "punctuation.definition.action.begin.jison"
357
+ }
358
+ },
359
+ "endCaptures": {
360
+ "0": {
361
+ "name": "punctuation.definition.action.end.jison"
362
+ }
363
+ },
364
+ "patterns": [
365
+ {
366
+ "include": "source.js"
367
+ }
368
+ ]
369
+ },
370
+ {
371
+ "name": "meta.action.jison",
372
+ "begin": "(?=%\\{)",
373
+ "end": "(?<=%\\})",
374
+ "patterns": [
375
+ {
376
+ "include": "#user_code_blocks"
377
+ }
378
+ ]
379
+ }
380
+ ]
381
+ },
382
+ "rule_actions": {
383
+ "patterns": [
384
+ {
385
+ "include": "#actions"
386
+ },
387
+ {
388
+ "name": "meta.action.jison",
389
+ "begin": "\\{",
390
+ "end": "\\}",
391
+ "beginCaptures": {
392
+ "0": {
393
+ "name": "punctuation.definition.action.begin.jison"
394
+ }
395
+ },
396
+ "endCaptures": {
397
+ "0": {
398
+ "name": "punctuation.definition.action.end.jison"
399
+ }
400
+ },
401
+ "patterns": [
402
+ {
403
+ "include": "source.js"
404
+ }
405
+ ]
406
+ },
407
+ {
408
+ "include": "#include_declarations"
409
+ },
410
+ {
411
+ "name": "meta.action.jison",
412
+ "begin": "->",
413
+ "end": "((//).*)?(?=$)",
414
+ "beginCaptures": {
415
+ "0": {
416
+ "name": "punctuation.definition.action.arrow.jison"
417
+ }
418
+ },
419
+ "endCaptures": {
420
+ "1": {
421
+ "name": "comment.line.double-slash.js"
422
+ },
423
+ "2": {
424
+ "name": "punctuation.definition.comment.js"
425
+ }
426
+ },
427
+ "patterns": [
428
+ {
429
+ "include": "source.js"
430
+ }
431
+ ]
432
+ }
433
+ ]
434
+ },
435
+ "comments": {
436
+ "patterns": [
437
+ {
438
+ "name": "comment.line.double-slash.jison",
439
+ "begin": "//",
440
+ "end": "(?=\\n)",
441
+ "beginCaptures": {
442
+ "0": {
443
+ "name": "punctuation.definition.comment.jison"
444
+ }
445
+ }
446
+ },
447
+ {
448
+ "name": "comment.block.jison",
449
+ "begin": "/\\*",
450
+ "end": "\\*/",
451
+ "beginCaptures": {
452
+ "0": {
453
+ "name": "punctuation.definition.comment.begin.jison"
454
+ }
455
+ },
456
+ "endCaptures": {
457
+ "0": {
458
+ "name": "punctuation.definition.comment.end.jison"
459
+ }
460
+ }
461
+ }
462
+ ]
463
+ },
464
+ "include_declarations": {
465
+ "patterns": [
466
+ {
467
+ "name": "meta.include.jison",
468
+ "begin": "(%(include))\\s*",
469
+ "end": "(?<=['\"])|(?=\\s)",
470
+ "beginCaptures": {
471
+ "1": {
472
+ "name": "keyword.other.declaration.$2.jison"
473
+ }
474
+ },
475
+ "patterns": [
476
+ {
477
+ "include": "#include_paths"
478
+ }
479
+ ]
480
+ }
481
+ ]
482
+ },
483
+ "user_code_include_declarations": {
484
+ "patterns": [
485
+ {
486
+ "name": "meta.include.jison",
487
+ "begin": "^(%(include))\\s*",
488
+ "end": "(?<=['\"])|(?=\\s)",
489
+ "beginCaptures": {
490
+ "1": {
491
+ "name": "keyword.other.declaration.$2.jison"
492
+ }
493
+ },
494
+ "patterns": [
495
+ {
496
+ "include": "#include_paths"
497
+ }
498
+ ]
499
+ }
500
+ ]
501
+ },
502
+ "include_paths": {
503
+ "patterns": [
504
+ {
505
+ "include": "#quoted_strings"
506
+ },
507
+ {
508
+ "name": "string.unquoted.jison",
509
+ "begin": "(?=\\S)",
510
+ "end": "(?=\\s)",
511
+ "patterns": [
512
+ {
513
+ "include": "source.js#string_escapes"
514
+ }
515
+ ]
516
+ }
517
+ ]
518
+ },
519
+ "numbers": {
520
+ "patterns": [
521
+ {
522
+ "match": "(0[Xx])(\\h+)",
523
+ "captures": {
524
+ "1": {
525
+ "name": "storage.type.number.jison"
526
+ },
527
+ "2": {
528
+ "name": "constant.numeric.integer.hexadecimal.jison"
529
+ }
530
+ }
531
+ },
532
+ {
533
+ "name": "constant.numeric.integer.decimal.jison",
534
+ "match": "\\d+"
535
+ }
536
+ ]
537
+ },
538
+ "options_declarations": {
539
+ "patterns": [
540
+ {
541
+ "name": "meta.options.jison",
542
+ "begin": "%options\\b",
543
+ "end": "$",
544
+ "beginCaptures": {
545
+ "0": {
546
+ "name": "keyword.other.options.jison"
547
+ }
548
+ },
549
+ "patterns": [
550
+ {
551
+ "name": "entity.name.constant.jison",
552
+ "match": "\\b[\\p{Alpha}_](?:[\\w-]*\\w)?\\b"
553
+ },
554
+ {
555
+ "begin": "(=)\\s*",
556
+ "end": "(?<=['\"])|(?=\\s)",
557
+ "beginCaptures": {
558
+ "1": {
559
+ "name": "keyword.operator.option.assignment.jison"
560
+ }
561
+ },
562
+ "patterns": [
563
+ {
564
+ "include": "quoted_strings"
565
+ },
566
+ {
567
+ "name": "string.unquoted.jison",
568
+ "match": "\\S+"
569
+ }
570
+ ]
571
+ },
572
+ {
573
+ "include": "quoted_strings"
574
+ }
575
+ ]
576
+ }
577
+ ]
578
+ },
579
+ "quoted_strings": {
580
+ "patterns": [
581
+ {
582
+ "name": "string.quoted.double.jison",
583
+ "begin": "\"",
584
+ "end": "\"",
585
+ "patterns": [
586
+ {
587
+ "include": "source.js#string_escapes"
588
+ }
589
+ ]
590
+ },
591
+ {
592
+ "name": "string.quoted.single.jison",
593
+ "begin": "'",
594
+ "end": "'",
595
+ "patterns": [
596
+ {
597
+ "include": "source.js#string_escapes"
598
+ }
599
+ ]
600
+ }
601
+ ]
602
+ },
603
+ "user_code_blocks": {
604
+ "patterns": [
605
+ {
606
+ "name": "meta.user-code-block.jison",
607
+ "begin": "%\\{",
608
+ "end": "%\\}",
609
+ "beginCaptures": {
610
+ "0": {
611
+ "name": "punctuation.definition.user-code-block.begin.jison"
612
+ }
613
+ },
614
+ "endCaptures": {
615
+ "0": {
616
+ "name": "punctuation.definition.user-code-block.end.jison"
617
+ }
618
+ },
619
+ "patterns": [
620
+ {
621
+ "include": "source.js"
622
+ }
623
+ ]
624
+ }
625
+ ]
626
+ }
627
+ },
628
+ "injections": {
629
+ "L:meta.action.jison -(comment | string), source.js.embedded.source": {
630
+ "patterns": [
631
+ {
632
+ "name": "variable.language.semantic-value.jison",
633
+ "match": "\\${2}"
634
+ },
635
+ {
636
+ "name": "variable.language.result-location.jison",
637
+ "match": "@\\$"
638
+ },
639
+ {
640
+ "name": "variable.language.stack-index-0.jison",
641
+ "match": "##\\$|\\byysp\\b"
642
+ },
643
+ {
644
+ "name": "support.variable.token-reference.jison",
645
+ "match": "#\\S+#"
646
+ },
647
+ {
648
+ "name": "variable.language.result-id.jison",
649
+ "match": "#\\$"
650
+ },
651
+ {
652
+ "name": "support.variable.token-value.jison",
653
+ "match": "\\$(?:-?\\d+|[\\p{Alpha}_](?:[\\w-]*\\w)?)"
654
+ },
655
+ {
656
+ "name": "support.variable.token-location.jison",
657
+ "match": "@(?:-?\\d+|[\\p{Alpha}_](?:[\\w-]*\\w)?)"
658
+ },
659
+ {
660
+ "name": "support.variable.stack-index.jison",
661
+ "match": "##(?:-?\\d+|[\\p{Alpha}_](?:[\\w-]*\\w)?)"
662
+ },
663
+ {
664
+ "name": "support.variable.token-id.jison",
665
+ "match": "#(?:-?\\d+|[\\p{Alpha}_](?:[\\w-]*\\w)?)"
666
+ },
667
+ {
668
+ "name": "variable.language.jison",
669
+ "match": "\\byy(?:l(?:eng|ineno|oc|stack)|s(?:tate|s?tack)|text|vstack)\\b"
670
+ },
671
+ {
672
+ "name": "keyword.other.jison",
673
+ "match": "\\byy(?:clearin|erro[kr])\\b"
674
+ }
675
+ ]
676
+ }
677
+ }
678
+ }