github-linguist 7.7.0 → 7.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/grammars/annotation.liquidhaskell.haskell.json +47 -0
- data/grammars/hidden.manref.json +1 -1
- data/grammars/hint.haskell.json +47 -0
- data/grammars/hint.message.haskell.json +47 -0
- data/grammars/hint.type.haskell.json +47 -0
- data/grammars/markdown.plantuml.codeblock.json +26 -0
- data/grammars/source.4dm.json +1100 -0
- data/grammars/source.abap.json +1 -1
- data/grammars/source.agda.json +32 -202
- data/grammars/source.ahk.json +6 -2
- data/grammars/source.chapel.json +4 -4
- data/grammars/source.csound.json +1 -1
- data/grammars/source.dart.json +57 -31
- data/grammars/source.dircolors.json +101 -3
- data/grammars/source.editorconfig.json +23 -5
- data/grammars/source.elixir.json +8 -0
- data/grammars/source.elm.json +1 -1
- data/grammars/source.emacs.lisp.json +10 -0
- data/grammars/source.faust.json +119 -0
- data/grammars/source.gcode.json +166 -8
- data/grammars/source.hack.json +4 -18
- data/grammars/source.haskell.json +47 -0
- data/grammars/source.hlsl.json +9 -5
- data/grammars/source.hsig.json +47 -0
- data/grammars/source.hx.json +4 -0
- data/grammars/source.igor.json +44 -0
- data/grammars/source.julia.json +25 -21
- data/grammars/source.lean.json +19 -3
- data/grammars/source.lean.markdown.json +2598 -0
- data/grammars/source.matlab.json +215 -152
- data/grammars/source.mcfunction-snapshot.json +1 -1
- data/grammars/source.meson.json +1 -1
- data/grammars/source.mrc.json +416 -534
- data/grammars/source.nasl.json +155 -0
- data/grammars/source.nextflow.json +2 -2
- data/grammars/source.odin-ehr.json +806 -0
- data/grammars/source.odin.json +402 -0
- data/grammars/source.prisma.json +7 -0
- data/grammars/source.qasm.json +66 -0
- data/grammars/source.ql.json +1408 -0
- data/grammars/source.scala.json +27 -3
- data/grammars/source.sy.json +2088 -183
- data/grammars/source.terraform.json +576 -132
- data/grammars/source.tnsaudit.json +256 -0
- data/grammars/source.ts.json +89 -30
- data/grammars/source.tsx.json +89 -30
- data/grammars/source.v.json +541 -788
- data/grammars/source.viml.json +2 -2
- data/grammars/source.webassembly.json +10 -0
- data/grammars/source.wsd.json +775 -0
- data/grammars/text.tex.latex.haskell.json +47 -0
- data/grammars/version +1 -1
- data/lib/linguist/VERSION +1 -1
- data/lib/linguist/file_blob.rb +1 -1
- data/lib/linguist/generated.rb +23 -3
- data/lib/linguist/heuristics.yml +48 -3
- data/lib/linguist/languages.json +1 -1
- data/lib/linguist/languages.yml +156 -34
- data/lib/linguist/lazy_blob.rb +10 -10
- data/lib/linguist/linguist.bundle +0 -0
- data/lib/linguist/samples.json +7739 -2010
- data/lib/linguist/shebang.rb +5 -3
- data/lib/linguist/vendor.yml +3 -0
- metadata +13 -7
- data/grammars/source.LS.json +0 -85
- data/grammars/source.MCPOST.json +0 -54
- data/grammars/source.MOD.json +0 -55
- data/grammars/source.apt.json +0 -18
- data/grammars/source.yaml-ext.json +0 -324
data/grammars/source.matlab.json
CHANGED
@@ -3,78 +3,91 @@
|
|
3
3
|
"scopeName": "source.matlab",
|
4
4
|
"patterns": [
|
5
5
|
{
|
6
|
-
"include": "#
|
7
|
-
},
|
8
|
-
{
|
9
|
-
"include": "#function"
|
10
|
-
},
|
11
|
-
{
|
12
|
-
"include": "#blocks"
|
13
|
-
},
|
14
|
-
{
|
15
|
-
"include": "#control_statements"
|
16
|
-
},
|
17
|
-
{
|
18
|
-
"include": "#global_persistent"
|
6
|
+
"include": "#all_before_command_dual"
|
19
7
|
},
|
20
8
|
{
|
21
9
|
"include": "#command_dual"
|
22
10
|
},
|
23
11
|
{
|
24
|
-
"include": "#
|
25
|
-
},
|
26
|
-
{
|
27
|
-
"include": "#line_continuation"
|
28
|
-
},
|
29
|
-
{
|
30
|
-
"include": "#comments"
|
31
|
-
},
|
32
|
-
{
|
33
|
-
"include": "#transpose"
|
34
|
-
},
|
35
|
-
{
|
36
|
-
"include": "#constants"
|
37
|
-
},
|
38
|
-
{
|
39
|
-
"include": "#variables"
|
40
|
-
},
|
41
|
-
{
|
42
|
-
"include": "#end_in_parens"
|
43
|
-
},
|
44
|
-
{
|
45
|
-
"include": "#numbers"
|
46
|
-
},
|
47
|
-
{
|
48
|
-
"include": "#operators"
|
12
|
+
"include": "#all_after_command_dual"
|
49
13
|
}
|
50
14
|
],
|
51
15
|
"repository": {
|
16
|
+
"all_after_command_dual": {
|
17
|
+
"patterns": [
|
18
|
+
{
|
19
|
+
"include": "#string"
|
20
|
+
},
|
21
|
+
{
|
22
|
+
"include": "#line_continuation"
|
23
|
+
},
|
24
|
+
{
|
25
|
+
"include": "#comments"
|
26
|
+
},
|
27
|
+
{
|
28
|
+
"include": "#conjugate_transpose"
|
29
|
+
},
|
30
|
+
{
|
31
|
+
"include": "#transpose"
|
32
|
+
},
|
33
|
+
{
|
34
|
+
"include": "#constants"
|
35
|
+
},
|
36
|
+
{
|
37
|
+
"include": "#variables"
|
38
|
+
},
|
39
|
+
{
|
40
|
+
"include": "#numbers"
|
41
|
+
},
|
42
|
+
{
|
43
|
+
"include": "#operators"
|
44
|
+
}
|
45
|
+
]
|
46
|
+
},
|
47
|
+
"all_before_command_dual": {
|
48
|
+
"patterns": [
|
49
|
+
{
|
50
|
+
"include": "#classdef"
|
51
|
+
},
|
52
|
+
{
|
53
|
+
"include": "#function"
|
54
|
+
},
|
55
|
+
{
|
56
|
+
"include": "#blocks"
|
57
|
+
},
|
58
|
+
{
|
59
|
+
"include": "#control_statements"
|
60
|
+
},
|
61
|
+
{
|
62
|
+
"include": "#global_persistent"
|
63
|
+
},
|
64
|
+
{
|
65
|
+
"include": "#parens"
|
66
|
+
},
|
67
|
+
{
|
68
|
+
"include": "#square_brackets"
|
69
|
+
},
|
70
|
+
{
|
71
|
+
"include": "#indexing_curly_brackets"
|
72
|
+
},
|
73
|
+
{
|
74
|
+
"include": "#curly_brackets"
|
75
|
+
}
|
76
|
+
]
|
77
|
+
},
|
52
78
|
"blocks": {
|
53
79
|
"patterns": [
|
54
80
|
{
|
55
81
|
"name": "meta.for.matlab",
|
56
|
-
"begin": "(
|
57
|
-
"end": "
|
82
|
+
"begin": "\\s*(?:^|[\\s,;])(for)\\b",
|
83
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
58
84
|
"patterns": [
|
59
|
-
{
|
60
|
-
"name": "meta.for-quantity.matlab",
|
61
|
-
"begin": "\\G(?!$)",
|
62
|
-
"end": "$\\n?",
|
63
|
-
"patterns": [
|
64
|
-
{
|
65
|
-
"include": "$self"
|
66
|
-
}
|
67
|
-
]
|
68
|
-
},
|
69
85
|
{
|
70
86
|
"include": "$self"
|
71
87
|
}
|
72
88
|
],
|
73
89
|
"beginCaptures": {
|
74
|
-
"
|
75
|
-
"name": "meta.for-quantity.matlab"
|
76
|
-
},
|
77
|
-
"2": {
|
90
|
+
"1": {
|
78
91
|
"name": "keyword.control.for.matlab"
|
79
92
|
}
|
80
93
|
},
|
@@ -86,27 +99,14 @@
|
|
86
99
|
},
|
87
100
|
{
|
88
101
|
"name": "meta.if.matlab",
|
89
|
-
"begin": "(
|
90
|
-
"end": "
|
102
|
+
"begin": "\\s*(?:^|[\\s,;])(if)\\b",
|
103
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
91
104
|
"patterns": [
|
92
|
-
{
|
93
|
-
"name": "meta.if-condition.matlab",
|
94
|
-
"begin": "\\G(?!$)",
|
95
|
-
"end": "$\\n?",
|
96
|
-
"patterns": [
|
97
|
-
{
|
98
|
-
"include": "$self"
|
99
|
-
}
|
100
|
-
]
|
101
|
-
},
|
102
105
|
{
|
103
106
|
"name": "meta.elseif.matlab",
|
104
|
-
"match": "(
|
107
|
+
"match": "(\\s*)(?:^|[\\s,;])(elseif)\\b(.*)$\\n?",
|
105
108
|
"end": "^",
|
106
109
|
"captures": {
|
107
|
-
"0": {
|
108
|
-
"name": "meta.elseif-condition.matlab"
|
109
|
-
},
|
110
110
|
"2": {
|
111
111
|
"name": "keyword.control.elseif.matlab"
|
112
112
|
},
|
@@ -121,12 +121,9 @@
|
|
121
121
|
},
|
122
122
|
{
|
123
123
|
"name": "meta.else.matlab",
|
124
|
-
"match": "(
|
124
|
+
"match": "(\\s*)(?:^|[\\s,;])(else)\\b(.*)?$\\n?",
|
125
125
|
"end": "^",
|
126
126
|
"captures": {
|
127
|
-
"0": {
|
128
|
-
"name": "meta.else-condition.matlab"
|
129
|
-
},
|
130
127
|
"2": {
|
131
128
|
"name": "keyword.control.else.matlab"
|
132
129
|
},
|
@@ -144,23 +141,27 @@
|
|
144
141
|
}
|
145
142
|
],
|
146
143
|
"beginCaptures": {
|
147
|
-
"
|
148
|
-
"name": "meta.if-condition.matlab"
|
149
|
-
},
|
150
|
-
"2": {
|
144
|
+
"1": {
|
151
145
|
"name": "keyword.control.if.matlab"
|
152
146
|
}
|
153
147
|
},
|
154
148
|
"endCaptures": {
|
155
149
|
"1": {
|
156
150
|
"name": "keyword.control.end.if.matlab"
|
151
|
+
},
|
152
|
+
"2": {
|
153
|
+
"patterns": [
|
154
|
+
{
|
155
|
+
"include": "$self"
|
156
|
+
}
|
157
|
+
]
|
157
158
|
}
|
158
159
|
}
|
159
160
|
},
|
160
161
|
{
|
161
162
|
"name": "meta.parfor.matlab",
|
162
|
-
"begin": "(
|
163
|
-
"end": "
|
163
|
+
"begin": "\\s*(?:^|[\\s,;])(parfor)\\b",
|
164
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
164
165
|
"patterns": [
|
165
166
|
{
|
166
167
|
"name": "meta.parfor-quantity.matlab",
|
@@ -177,10 +178,7 @@
|
|
177
178
|
}
|
178
179
|
],
|
179
180
|
"beginCaptures": {
|
180
|
-
"
|
181
|
-
"name": "meta.parfor-quantity.matlab"
|
182
|
-
},
|
183
|
-
"2": {
|
181
|
+
"1": {
|
184
182
|
"name": "keyword.control.for.matlab"
|
185
183
|
}
|
186
184
|
},
|
@@ -192,8 +190,8 @@
|
|
192
190
|
},
|
193
191
|
{
|
194
192
|
"name": "meta.spmd.matlab",
|
195
|
-
"begin": "(
|
196
|
-
"end": "
|
193
|
+
"begin": "\\s*(?:^|[\\s,;])(spmd)\\b",
|
194
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
197
195
|
"patterns": [
|
198
196
|
{
|
199
197
|
"name": "meta.spmd-statement.matlab",
|
@@ -210,10 +208,7 @@
|
|
210
208
|
}
|
211
209
|
],
|
212
210
|
"beginCaptures": {
|
213
|
-
"
|
214
|
-
"name": "meta.spmd-statement.matlab"
|
215
|
-
},
|
216
|
-
"2": {
|
211
|
+
"1": {
|
217
212
|
"name": "keyword.control.spmd.matlab"
|
218
213
|
}
|
219
214
|
},
|
@@ -225,27 +220,14 @@
|
|
225
220
|
},
|
226
221
|
{
|
227
222
|
"name": "meta.switch.matlab",
|
228
|
-
"begin": "(
|
229
|
-
"end": "
|
223
|
+
"begin": "\\s*(?:^|[\\s,;])(switch)\\b",
|
224
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
230
225
|
"patterns": [
|
231
|
-
{
|
232
|
-
"name": "meta.switch-expression.matlab",
|
233
|
-
"begin": "\\G(?!$)",
|
234
|
-
"end": "$\\n?",
|
235
|
-
"patterns": [
|
236
|
-
{
|
237
|
-
"include": "$self"
|
238
|
-
}
|
239
|
-
]
|
240
|
-
},
|
241
226
|
{
|
242
227
|
"name": "meta.case.matlab",
|
243
|
-
"match": "(
|
228
|
+
"match": "(\\s*)(?:^|[\\s,;])(case)\\b(.*)$\\n?",
|
244
229
|
"end": "^",
|
245
230
|
"captures": {
|
246
|
-
"0": {
|
247
|
-
"name": "meta.case-expression.matlab"
|
248
|
-
},
|
249
231
|
"2": {
|
250
232
|
"name": "keyword.control.case.matlab"
|
251
233
|
},
|
@@ -260,12 +242,9 @@
|
|
260
242
|
},
|
261
243
|
{
|
262
244
|
"name": "meta.otherwise.matlab",
|
263
|
-
"match": "(
|
245
|
+
"match": "(\\s*)(?:^|[\\s,;])(otherwise)\\b(.*)?$\\n?",
|
264
246
|
"end": "^",
|
265
247
|
"captures": {
|
266
|
-
"0": {
|
267
|
-
"name": "meta.otherwise-expression.matlab"
|
268
|
-
},
|
269
248
|
"2": {
|
270
249
|
"name": "keyword.control.otherwise.matlab"
|
271
250
|
},
|
@@ -283,10 +262,7 @@
|
|
283
262
|
}
|
284
263
|
],
|
285
264
|
"beginCaptures": {
|
286
|
-
"
|
287
|
-
"name": "meta.switch-expression.matlab"
|
288
|
-
},
|
289
|
-
"2": {
|
265
|
+
"1": {
|
290
266
|
"name": "keyword.control.switch.matlab"
|
291
267
|
}
|
292
268
|
},
|
@@ -298,17 +274,14 @@
|
|
298
274
|
},
|
299
275
|
{
|
300
276
|
"name": "meta.try.matlab",
|
301
|
-
"begin": "(
|
302
|
-
"end": "
|
277
|
+
"begin": "\\s*(?:^|[\\s,;])(try)\\b",
|
278
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
303
279
|
"patterns": [
|
304
280
|
{
|
305
281
|
"name": "meta.catch.matlab",
|
306
|
-
"match": "(
|
282
|
+
"match": "(\\s*)(?:^|[\\s,;])(catch)\\b(.*)?$\\n?",
|
307
283
|
"end": "^",
|
308
284
|
"captures": {
|
309
|
-
"0": {
|
310
|
-
"name": "meta.catch-exception.matlab"
|
311
|
-
},
|
312
285
|
"2": {
|
313
286
|
"name": "keyword.control.catch.matlab"
|
314
287
|
},
|
@@ -326,7 +299,7 @@
|
|
326
299
|
}
|
327
300
|
],
|
328
301
|
"beginCaptures": {
|
329
|
-
"
|
302
|
+
"1": {
|
330
303
|
"name": "keyword.control.try.matlab"
|
331
304
|
}
|
332
305
|
},
|
@@ -338,28 +311,15 @@
|
|
338
311
|
},
|
339
312
|
{
|
340
313
|
"name": "meta.while.matlab",
|
341
|
-
"begin": "(
|
342
|
-
"end": "
|
314
|
+
"begin": "\\s*(?:^|[\\s,;])(while)\\b",
|
315
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
343
316
|
"patterns": [
|
344
|
-
{
|
345
|
-
"name": "meta.while-condition.matlab",
|
346
|
-
"begin": "\\G(?!$)",
|
347
|
-
"end": "$\\n?",
|
348
|
-
"patterns": [
|
349
|
-
{
|
350
|
-
"include": "$self"
|
351
|
-
}
|
352
|
-
]
|
353
|
-
},
|
354
317
|
{
|
355
318
|
"include": "$self"
|
356
319
|
}
|
357
320
|
],
|
358
321
|
"beginCaptures": {
|
359
|
-
"
|
360
|
-
"name": "meta.while-condition.matlab"
|
361
|
-
},
|
362
|
-
"2": {
|
322
|
+
"1": {
|
363
323
|
"name": "keyword.control.while.matlab"
|
364
324
|
}
|
365
325
|
},
|
@@ -413,12 +373,12 @@
|
|
413
373
|
{
|
414
374
|
"name": "meta.class.matlab",
|
415
375
|
"begin": "(?x)\n\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t(classdef)\n\t\t\t\t\t\t\t\\b\\s*\n\t\t\t\t\t\t\t(.*)\n\t\t\t\t\t",
|
416
|
-
"end": "
|
376
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
417
377
|
"patterns": [
|
418
378
|
{
|
419
379
|
"name": "meta.properties.matlab",
|
420
|
-
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(properties)\\b(
|
421
|
-
"end": "
|
380
|
+
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(properties)\\b([^%]*)\n\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t(\t\t\t\t\t\t\t\t\t# Optional attributes\n\t\t\t\t\t\t\t\t\t\t\\( [^)]* \\)\n\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\\s*($|(?=%))\n\t\t\t\t\t\t\t\t",
|
381
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
422
382
|
"patterns": [
|
423
383
|
{
|
424
384
|
"include": "#validators"
|
@@ -462,8 +422,8 @@
|
|
462
422
|
},
|
463
423
|
{
|
464
424
|
"name": "meta.methods.matlab",
|
465
|
-
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(methods)\\b(
|
466
|
-
"end": "
|
425
|
+
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(methods)\\b([^%]*)\n\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t(\t\t\t\t\t\t\t\t\t# Optional attributes\n\t\t\t\t\t\t\t\t\t\t\\( [^)]* \\)\n\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\\s*($|(?=%))\n\t\t\t\t\t\t\t\t",
|
426
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
467
427
|
"patterns": [
|
468
428
|
{
|
469
429
|
"include": "$self"
|
@@ -504,8 +464,13 @@
|
|
504
464
|
},
|
505
465
|
{
|
506
466
|
"name": "meta.events.matlab",
|
507
|
-
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(events)\\b(
|
508
|
-
"end": "
|
467
|
+
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(events)\\b([^%]*)\n\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t(\t\t\t\t\t\t\t\t\t# Optional attributes\n\t\t\t\t\t\t\t\t\t\t\\( [^)]* \\)\n\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\\s*($|(?=%))\n\t\t\t\t\t\t\t\t",
|
468
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
469
|
+
"patterns": [
|
470
|
+
{
|
471
|
+
"include": "$self"
|
472
|
+
}
|
473
|
+
],
|
509
474
|
"beginCaptures": {
|
510
475
|
"2": {
|
511
476
|
"name": "keyword.control.events.matlab"
|
@@ -541,8 +506,8 @@
|
|
541
506
|
},
|
542
507
|
{
|
543
508
|
"name": "meta.enumeration.matlab",
|
544
|
-
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(enumeration)\\b(
|
545
|
-
"end": "
|
509
|
+
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(enumeration)\\b([^%]*)\n\t\t\t\t\t\t\t\t\t\\s*($|(?=%))\n\t\t\t\t\t\t\t\t",
|
510
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
546
511
|
"patterns": [
|
547
512
|
{
|
548
513
|
"include": "$self"
|
@@ -570,7 +535,7 @@
|
|
570
535
|
"3": {
|
571
536
|
"patterns": [
|
572
537
|
{
|
573
|
-
"match": "(?x)\n\t\t\t\t\t\t\t\t\t\t(\t\t\t\t\t\t\t\t\t# Optional attributes\n\t\t\t\t\t\t\t\t\t\t\t \\( [^)]* \\)\n\t\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t\t(\n\t\t\t\t\t\t\t\t\t\t\t([a-zA-Z][a-zA-Z0-9_]*)\t\t\t# Class name\n\t\t\t\t\t\t\t\t\t\t\t(?:\t\t\t\t\t\t\t\t# Optional inheritance\n\t\t\t\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t\t\t\t(\u003c)\n\t\t\t\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t\t\t\t([^%]*)\n\t\t\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\\s*($|(?=(%|...)))\n\t\t\t\t\t\t\t\t\t",
|
538
|
+
"match": "(?x)\n\t\t\t\t\t\t\t\t\t\t(\t\t\t\t\t\t\t\t\t# Optional attributes\n\t\t\t\t\t\t\t\t\t\t\t \\( [^)]* \\)\n\t\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t\t(\n\t\t\t\t\t\t\t\t\t\t\t([a-zA-Z][a-zA-Z0-9_]*)\t\t\t# Class name\n\t\t\t\t\t\t\t\t\t\t\t(?:\t\t\t\t\t\t\t\t# Optional inheritance\n\t\t\t\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t\t\t\t(\u003c)\n\t\t\t\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t\t\t\t([^%]*)\n\t\t\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\\s*($|(?=(%|...)).*)\n\t\t\t\t\t\t\t\t\t",
|
574
539
|
"captures": {
|
575
540
|
"1": {
|
576
541
|
"patterns": [
|
@@ -613,6 +578,13 @@
|
|
613
578
|
"match": "\u0026"
|
614
579
|
}
|
615
580
|
]
|
581
|
+
},
|
582
|
+
"6": {
|
583
|
+
"patterns": [
|
584
|
+
{
|
585
|
+
"include": "$self"
|
586
|
+
}
|
587
|
+
]
|
616
588
|
}
|
617
589
|
}
|
618
590
|
}
|
@@ -715,19 +687,44 @@
|
|
715
687
|
}
|
716
688
|
]
|
717
689
|
},
|
690
|
+
"conjugate_transpose": {
|
691
|
+
"name": "keyword.operator.transpose.matlab",
|
692
|
+
"match": "((?\u003c=[^\\s])|(?\u003c=\\])|(?\u003c=\\))|(?\u003c=\\}))'"
|
693
|
+
},
|
718
694
|
"constants": {
|
719
695
|
"name": "constant.language.matlab",
|
720
696
|
"match": "(?\u003c!\\.)\\b(eps|false|Inf|inf|intmax|intmin|namelengthmax|NaN|nan|on|off|realmax|realmin|true|pi)\\b"
|
721
697
|
},
|
722
698
|
"control_statements": {
|
723
699
|
"name": "meta.control.matlab",
|
724
|
-
"match": "
|
700
|
+
"match": "\\s*(?:^|[\\s,;])(break|continue|return)\\b",
|
725
701
|
"captures": {
|
726
702
|
"1": {
|
727
703
|
"name": "keyword.control.matlab"
|
728
704
|
}
|
729
705
|
}
|
730
706
|
},
|
707
|
+
"curly_brackets": {
|
708
|
+
"begin": "\\{",
|
709
|
+
"end": "\\}",
|
710
|
+
"patterns": [
|
711
|
+
{
|
712
|
+
"include": "#end_in_parens"
|
713
|
+
},
|
714
|
+
{
|
715
|
+
"include": "#all_before_command_dual"
|
716
|
+
},
|
717
|
+
{
|
718
|
+
"include": "#all_after_command_dual"
|
719
|
+
},
|
720
|
+
{
|
721
|
+
"include": "#end_in_parens"
|
722
|
+
},
|
723
|
+
{
|
724
|
+
"include": "#block_keywords"
|
725
|
+
}
|
726
|
+
]
|
727
|
+
},
|
731
728
|
"end_in_parens": {
|
732
729
|
"name": "keyword.operator.symbols.matlab",
|
733
730
|
"match": "\\bend\\b"
|
@@ -737,13 +734,16 @@
|
|
737
734
|
{
|
738
735
|
"name": "meta.function.matlab",
|
739
736
|
"begin": "(?x)\n\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t(function)\n\t\t\t\t\t\t\t\\s+\n\t\t\t\t\t\t\t(?:\t\t\t\t\t\t\t\t\t\t\t\t\t# Optional\n\t\t\t\t\t\t\t\t(?:\n\t\t\t\t\t\t\t\t\t(\\[) ([^\\]]*) (\\])\n\t\t\t\t\t\t\t\t | ([a-zA-Z][a-zA-Z0-9_]*)\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\\s* = \\s*\n\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t([a-zA-Z][a-zA-Z0-9_]*(\\.[a-zA-Z][a-zA-Z0-9_]*)*)\t# Function name\n\t\t\t\t\t\t\t\\s*\t\t\t\t\t\t\t\t\t\t\t\t\t# Trailing space\n\t\t\t\t\t\t",
|
740
|
-
"end": "
|
737
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b(\\s*\\n)?",
|
741
738
|
"patterns": [
|
742
739
|
{
|
743
740
|
"name": "meta.arguments.function.matlab",
|
744
741
|
"begin": "\\G\\(",
|
745
742
|
"end": "\\)",
|
746
743
|
"patterns": [
|
744
|
+
{
|
745
|
+
"include": "#line_continuation"
|
746
|
+
},
|
747
747
|
{
|
748
748
|
"name": "variable.parameter.input.matlab",
|
749
749
|
"match": "\\w+"
|
@@ -752,8 +752,8 @@
|
|
752
752
|
},
|
753
753
|
{
|
754
754
|
"name": "meta.arguments.matlab",
|
755
|
-
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(arguments)\\b(
|
756
|
-
"end": "
|
755
|
+
"begin": "(?x)\n\t\t\t\t\t\t\t\t\t(^\\s*)\t\t\t\t\t\t\t\t# Leading whitespace\n\t\t\t\t\t\t\t\t\t(arguments)\\b([^%]*)\n\t\t\t\t\t\t\t\t\t\\s*\n\t\t\t\t\t\t\t\t\t(\t\t\t\t\t\t\t\t\t# Optional attributes\n\t\t\t\t\t\t\t\t\t\t\\( [^)]* \\)\n\t\t\t\t\t\t\t\t\t)?\n\t\t\t\t\t\t\t\t\t\\s*($|(?=%))\n\t\t\t\t\t\t\t\t",
|
756
|
+
"end": "\\s*(?:^|[\\s,;])(end)\\b",
|
757
757
|
"patterns": [
|
758
758
|
{
|
759
759
|
"include": "#validators"
|
@@ -827,6 +827,36 @@
|
|
827
827
|
}
|
828
828
|
}
|
829
829
|
},
|
830
|
+
"indexing_curly_brackets": {
|
831
|
+
"begin": "([a-zA-Z][a-zA-Z0-9_\\.]*\\s*)\\{",
|
832
|
+
"end": "(\\}|(?\u003c!\\.\\.\\.).\\n)",
|
833
|
+
"patterns": [
|
834
|
+
{
|
835
|
+
"include": "#end_in_parens"
|
836
|
+
},
|
837
|
+
{
|
838
|
+
"include": "#all_before_command_dual"
|
839
|
+
},
|
840
|
+
{
|
841
|
+
"include": "#all_after_command_dual"
|
842
|
+
},
|
843
|
+
{
|
844
|
+
"include": "#end_in_parens"
|
845
|
+
},
|
846
|
+
{
|
847
|
+
"include": "#block_keywords"
|
848
|
+
}
|
849
|
+
],
|
850
|
+
"beginCaptures": {
|
851
|
+
"1": {
|
852
|
+
"patterns": [
|
853
|
+
{
|
854
|
+
"include": "$self"
|
855
|
+
}
|
856
|
+
]
|
857
|
+
}
|
858
|
+
}
|
859
|
+
},
|
830
860
|
"line_continuation": {
|
831
861
|
"name": "meta.linecontinuation.matlab",
|
832
862
|
"match": "(\\.\\.\\.)(.*)$",
|
@@ -847,6 +877,39 @@
|
|
847
877
|
"name": "keyword.operator.symbols.matlab",
|
848
878
|
"match": "(?\u003c=\\s)(==|~=|\u003e|\u003e=|\u003c|\u003c=|\u0026|\u0026\u0026|:|\\||\\|\\||\\+|-|\\*|\\.\\*|/|\\./|\\\\|\\.\\\\|\\^|\\.\\^)(?=\\s)"
|
849
879
|
},
|
880
|
+
"parens": {
|
881
|
+
"begin": "\\(",
|
882
|
+
"end": "(\\)|(?\u003c!\\.\\.\\.).\\n)",
|
883
|
+
"patterns": [
|
884
|
+
{
|
885
|
+
"include": "#end_in_parens"
|
886
|
+
},
|
887
|
+
{
|
888
|
+
"include": "#all_before_command_dual"
|
889
|
+
},
|
890
|
+
{
|
891
|
+
"include": "#all_after_command_dual"
|
892
|
+
},
|
893
|
+
{
|
894
|
+
"include": "#block_keywords"
|
895
|
+
}
|
896
|
+
]
|
897
|
+
},
|
898
|
+
"square_brackets": {
|
899
|
+
"begin": "\\[",
|
900
|
+
"end": "\\]",
|
901
|
+
"patterns": [
|
902
|
+
{
|
903
|
+
"include": "#all_before_command_dual"
|
904
|
+
},
|
905
|
+
{
|
906
|
+
"include": "#all_after_command_dual"
|
907
|
+
},
|
908
|
+
{
|
909
|
+
"include": "#block_keywords"
|
910
|
+
}
|
911
|
+
]
|
912
|
+
},
|
850
913
|
"string": {
|
851
914
|
"patterns": [
|
852
915
|
{
|
@@ -918,7 +981,7 @@
|
|
918
981
|
},
|
919
982
|
"transpose": {
|
920
983
|
"name": "keyword.operator.transpose.matlab",
|
921
|
-
"match": "
|
984
|
+
"match": "\\.'"
|
922
985
|
},
|
923
986
|
"validator_strings": {
|
924
987
|
"patterns": [
|