tm-grammars 1.25.3 → 1.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NOTICE +527 -30
- package/README.md +38 -33
- package/grammars/apex.json +102 -16
- package/grammars/berry.json +78 -32
- package/grammars/blade.json +91 -16
- package/grammars/c3.json +1982 -0
- package/grammars/csharp.json +126 -0
- package/grammars/fortran-fixed-form.json +37 -0
- package/grammars/fortran-free-form.json +178 -49
- package/grammars/gn.json +155 -0
- package/grammars/kusto.json +1 -1
- package/grammars/lean.json +1 -5
- package/grammars/luau.json +2 -2
- package/grammars/markdown-nix.json +50 -0
- package/grammars/markdown-vue.json +1 -1
- package/grammars/marko.json +8 -8
- package/grammars/mermaid.json +68 -4
- package/grammars/mojo.json +1 -1
- package/grammars/moonbit.json +393 -0
- package/grammars/nextflow.json +21 -0
- package/grammars/nix.json +8 -2
- package/grammars/openscad.json +151 -0
- package/grammars/proto.json +5 -5
- package/grammars/r.json +325 -669
- package/grammars/razor.json +134 -19
- package/grammars/solidity.json +2 -18
- package/grammars/svelte.json +13 -2
- package/grammars/tex.json +1 -1
- package/grammars/typespec.json +36 -33
- package/grammars/vue-directives.json +1 -1
- package/grammars/vue-interpolations.json +1 -1
- package/grammars/vue.json +279 -45
- package/index.js +271 -162
- package/package.json +1 -1
package/grammars/luau.json
CHANGED
|
@@ -484,11 +484,11 @@
|
|
|
484
484
|
"name": "constant.language.luau"
|
|
485
485
|
},
|
|
486
486
|
{
|
|
487
|
-
"match": "(?<![^.]\\.|:)\\b(bit32\\.(?:arshift|band|bnot|bor|btest|bxor|extract|lrotate|lshift|replace|rrotate|rshift|countlz|countrz|byteswap)|coroutine\\.(?:create|isyieldable|resume|running|status|wrap|yield|close)|debug\\.(?:info|loadmodule|profilebegin|profileend|traceback)|math\\.(?:abs|acos|asin|atan2??|ceil|clamp|cosh??|deg|exp|floor|fmod|frexp|ldexp|log|log10|max|min|modf|noise|pow|rad|random|randomseed|round|sign|sinh??|sqrt|tanh??)|os\\.(?:clock|date|difftime|time)|string\\.(?:byte|char|find|format|gmatch|gsub|len|lower|match|pack|packsize|rep|reverse|split|sub|unpack|upper)|table\\.(?:concat|create|find|foreachi??|getn|insert|maxn|move|pack|remove|sort|unpack|clear|freeze|isfrozen|clone)|task\\.(?:spawn|synchronize|desynchronize|wait|defer|delay)|utf8\\.(?:char|codepoint|codes|graphemes|len|nfcnormalize|nfdnormalize|offset)|buffer\\.(?:create|fromstring|tostring|len|readi8|readu8|readi16|readu16|readi32|readu32|readf32|readf64|writei8|writeu8|writei16|writeu16|writei32|writeu32|writef32|writef64|readstring|writestring|copy|fill))\\b",
|
|
487
|
+
"match": "(?<![^.]\\.|:)\\b(bit32\\.(?:arshift|band|bnot|bor|btest|bxor|extract|lrotate|lshift|replace|rrotate|rshift|countlz|countrz|byteswap)|coroutine\\.(?:create|isyieldable|resume|running|status|wrap|yield|close)|debug\\.(?:info|loadmodule|profilebegin|profileend|traceback)|math\\.(?:abs|acos|asin|atan2??|ceil|clamp|cosh??|deg|exp|floor|fmod|frexp|ldexp|log|log10|max|min|modf|noise|pow|rad|random|randomseed|round|sign|sinh??|sqrt|tanh??)|os\\.(?:clock|date|difftime|time)|string\\.(?:byte|char|find|format|gmatch|gsub|len|lower|match|pack|packsize|rep|reverse|split|sub|unpack|upper)|table\\.(?:concat|create|find|foreachi??|getn|insert|maxn|move|pack|remove|sort|unpack|clear|freeze|isfrozen|clone)|task\\.(?:spawn|synchronize|desynchronize|wait|defer|delay)|utf8\\.(?:char|codepoint|codes|graphemes|len|nfcnormalize|nfdnormalize|offset)|buffer\\.(?:create|fromstring|tostring|len|readi8|readu8|readi16|readu16|readi32|readu32|readf32|readf64|writei8|writeu8|writei16|writeu16|writei32|writeu32|writef32|writef64|readstring|writestring|copy|fill)|vector\\.(?:abs|angle|ceil|clamp|create|cross|dot|floor|lerp|magnitude|max|min|normalize|sign))\\b",
|
|
488
488
|
"name": "support.function.luau"
|
|
489
489
|
},
|
|
490
490
|
{
|
|
491
|
-
"match": "(?<![^.]\\.|:)\\b(bit32|buffer|coroutine|debug|math(\\.(huge|pi))?|os|string|table|task|utf8(\\.charpattern)?)\\b",
|
|
491
|
+
"match": "(?<![^.]\\.|:)\\b(bit32|buffer|coroutine|debug|math(\\.(huge|pi))?|os|string|table|task|utf8(\\.charpattern)?|vector(\\.(one|zero))?)\\b",
|
|
492
492
|
"name": "support.constant.luau"
|
|
493
493
|
},
|
|
494
494
|
{
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
{
|
|
2
|
+
"fileTypes": [
|
|
3
|
+
],
|
|
4
|
+
"injectTo": [
|
|
5
|
+
"text.html.markdown"
|
|
6
|
+
],
|
|
7
|
+
"injectionSelector": "L:text.html.markdown",
|
|
8
|
+
"name": "markdown-nix",
|
|
9
|
+
"patterns": [
|
|
10
|
+
{
|
|
11
|
+
"include": "#nix-code-block"
|
|
12
|
+
}
|
|
13
|
+
],
|
|
14
|
+
"repository": {
|
|
15
|
+
"nix-code-block": {
|
|
16
|
+
"begin": "(^|\\G)(\\s*)(`{3,}|~{3,})\\s*(?i:(nix)(\\s+[^`~]*)?$)",
|
|
17
|
+
"beginCaptures": {
|
|
18
|
+
"3": {
|
|
19
|
+
"name": "punctuation.definition.markdown"
|
|
20
|
+
},
|
|
21
|
+
"5": {
|
|
22
|
+
"name": "fenced_code.block.language"
|
|
23
|
+
},
|
|
24
|
+
"6": {
|
|
25
|
+
"name": "fenced_code.block.language.attributes"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"end": "(^|\\G)(\\2|\\s{0,3})(\\3)\\s*$",
|
|
29
|
+
"endCaptures": {
|
|
30
|
+
"3": {
|
|
31
|
+
"name": "punctuation.definition.markdown"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"name": "markup.fenced_code.block.markdown",
|
|
35
|
+
"patterns": [
|
|
36
|
+
{
|
|
37
|
+
"begin": "(^|\\G)(\\s*)(.*)",
|
|
38
|
+
"contentName": "meta.embedded.block.nix",
|
|
39
|
+
"patterns": [
|
|
40
|
+
{
|
|
41
|
+
"include": "source.nix"
|
|
42
|
+
}
|
|
43
|
+
],
|
|
44
|
+
"while": "(^|\\G)(?!\\s*([`~]{3,})\\s*$)"
|
|
45
|
+
}
|
|
46
|
+
]
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"scopeName": "markdown.nix.codeblock"
|
|
50
|
+
}
|
package/grammars/marko.json
CHANGED
|
@@ -942,7 +942,7 @@
|
|
|
942
942
|
"name": "invalid.illegal.character-not-allowed-here.marko"
|
|
943
943
|
},
|
|
944
944
|
"invalid-close-tag": {
|
|
945
|
-
"begin": "\\s
|
|
945
|
+
"begin": "\\s*</[^>]*",
|
|
946
946
|
"end": ">",
|
|
947
947
|
"name": "invalid.illegal.character-not-allowed-here.marko"
|
|
948
948
|
},
|
|
@@ -1336,7 +1336,7 @@
|
|
|
1336
1336
|
"name": "punctuation.definition.tag.begin.marko"
|
|
1337
1337
|
}
|
|
1338
1338
|
},
|
|
1339
|
-
"end": "/>|(?<=</\\2
|
|
1339
|
+
"end": "/>|(?<=</>)|(?<=</\\2>)",
|
|
1340
1340
|
"endCaptures": {
|
|
1341
1341
|
"0": {
|
|
1342
1342
|
"name": "punctuation.definition.tag.end.marko"
|
|
@@ -1385,7 +1385,7 @@
|
|
|
1385
1385
|
"name": "punctuation.definition.tag.begin.marko"
|
|
1386
1386
|
}
|
|
1387
1387
|
},
|
|
1388
|
-
"end": "/>|(?<=</\\2
|
|
1388
|
+
"end": "/>|(?<=</>)|(?<=</\\2>)",
|
|
1389
1389
|
"endCaptures": {
|
|
1390
1390
|
"0": {
|
|
1391
1391
|
"name": "punctuation.definition.tag.end.marko"
|
|
@@ -1434,7 +1434,7 @@
|
|
|
1434
1434
|
"name": "punctuation.definition.tag.begin.marko"
|
|
1435
1435
|
}
|
|
1436
1436
|
},
|
|
1437
|
-
"end": "/>|(?<=</\\2
|
|
1437
|
+
"end": "/>|(?<=</>)|(?<=</\\2>)",
|
|
1438
1438
|
"endCaptures": {
|
|
1439
1439
|
"0": {
|
|
1440
1440
|
"name": "punctuation.definition.tag.end.marko"
|
|
@@ -1483,7 +1483,7 @@
|
|
|
1483
1483
|
"name": "punctuation.definition.tag.begin.marko"
|
|
1484
1484
|
}
|
|
1485
1485
|
},
|
|
1486
|
-
"end": "/>|(?<=</\\2
|
|
1486
|
+
"end": "/>|(?<=</>)|(?<=</\\2>)",
|
|
1487
1487
|
"endCaptures": {
|
|
1488
1488
|
"0": {
|
|
1489
1489
|
"name": "punctuation.definition.tag.end.marko"
|
|
@@ -1532,7 +1532,7 @@
|
|
|
1532
1532
|
"name": "punctuation.definition.tag.begin.marko"
|
|
1533
1533
|
}
|
|
1534
1534
|
},
|
|
1535
|
-
"end": "/>|(?<=</\\2
|
|
1535
|
+
"end": "/>|(?<=</>)|(?<=</\\2>)",
|
|
1536
1536
|
"endCaptures": {
|
|
1537
1537
|
"0": {
|
|
1538
1538
|
"name": "punctuation.definition.tag.end.marko"
|
|
@@ -1581,7 +1581,7 @@
|
|
|
1581
1581
|
"name": "punctuation.definition.tag.begin.marko"
|
|
1582
1582
|
}
|
|
1583
1583
|
},
|
|
1584
|
-
"end": "/>|(?<=</\\2
|
|
1584
|
+
"end": "/>|(?<=</>)|(?<=</\\2>)",
|
|
1585
1585
|
"endCaptures": {
|
|
1586
1586
|
"0": {
|
|
1587
1587
|
"name": "punctuation.definition.tag.end.marko"
|
|
@@ -1598,7 +1598,7 @@
|
|
|
1598
1598
|
"name": "punctuation.definition.tag.end.marko"
|
|
1599
1599
|
}
|
|
1600
1600
|
},
|
|
1601
|
-
"end": "\\s*(</)([-#$.0-:@-Z_a-z]+)?(
|
|
1601
|
+
"end": "\\s*(</)([-#$.0-:@-Z_a-z]+)?([^>]*)(>)",
|
|
1602
1602
|
"endCaptures": {
|
|
1603
1603
|
"1": {
|
|
1604
1604
|
"name": "punctuation.definition.tag.begin.marko"
|
package/grammars/mermaid.json
CHANGED
|
@@ -458,7 +458,7 @@
|
|
|
458
458
|
"match": "(?i)^\\s*([-\\w]+)\\s*(\\[)?\\s*([-\\w]+|\"[-\\w\\s]+\")?\\s*(])?$"
|
|
459
459
|
},
|
|
460
460
|
{
|
|
461
|
-
"begin": "(?i)\\s
|
|
461
|
+
"begin": "(?i)\\s*([-\\w]+)\\s*(\\[)?\\s*([-\\w]+|\"[-\\w\\s]+\")?\\s*(])?\\s*(\\{)",
|
|
462
462
|
"beginCaptures": {
|
|
463
463
|
"1": {
|
|
464
464
|
"name": "variable"
|
|
@@ -498,7 +498,7 @@
|
|
|
498
498
|
"name": "string"
|
|
499
499
|
}
|
|
500
500
|
},
|
|
501
|
-
"match": "(?i)\\s*([-\\w]+)\\s+([-\\w]+)\\s+([FPU]K(?:,\\s*[FPU]K){0,2})?\\s*(\"[
|
|
501
|
+
"match": "(?i)\\s*([-\\w]+)\\s+([-\\w]+)\\s+([FPU]K(?:,\\s*[FPU]K){0,2})?\\s*(\"[^\\n\\r\"]*\")?\\s*"
|
|
502
502
|
},
|
|
503
503
|
{
|
|
504
504
|
"match": "%%.*",
|
|
@@ -1081,6 +1081,70 @@
|
|
|
1081
1081
|
}
|
|
1082
1082
|
]
|
|
1083
1083
|
},
|
|
1084
|
+
{
|
|
1085
|
+
"begin": "^\\s*(mindmap)",
|
|
1086
|
+
"beginCaptures": {
|
|
1087
|
+
"1": {
|
|
1088
|
+
"name": "keyword.control.mermaid"
|
|
1089
|
+
}
|
|
1090
|
+
},
|
|
1091
|
+
"end": "(^|\\G)(?=\\s*[:`~]{3,}\\s*$)",
|
|
1092
|
+
"patterns": [
|
|
1093
|
+
{
|
|
1094
|
+
"match": "%%.*",
|
|
1095
|
+
"name": "comment"
|
|
1096
|
+
},
|
|
1097
|
+
{
|
|
1098
|
+
"captures": {
|
|
1099
|
+
"1": {
|
|
1100
|
+
"name": "keyword.control.mermaid"
|
|
1101
|
+
},
|
|
1102
|
+
"2": {
|
|
1103
|
+
"name": "string"
|
|
1104
|
+
}
|
|
1105
|
+
},
|
|
1106
|
+
"match": "(?i)(\\s*:::)(\\s*[!-$\\&'*-/;-?\\\\^\\w\\s]*)"
|
|
1107
|
+
},
|
|
1108
|
+
{
|
|
1109
|
+
"captures": {
|
|
1110
|
+
"1": {
|
|
1111
|
+
"name": "keyword.control.mermaid"
|
|
1112
|
+
},
|
|
1113
|
+
"2": {
|
|
1114
|
+
"name": "punctuation.parenthesis.open.mermaid"
|
|
1115
|
+
},
|
|
1116
|
+
"3": {
|
|
1117
|
+
"name": "string"
|
|
1118
|
+
},
|
|
1119
|
+
"4": {
|
|
1120
|
+
"name": "punctuation.parenthesis.close.mermaid"
|
|
1121
|
+
}
|
|
1122
|
+
},
|
|
1123
|
+
"match": "(?i)(\\s*::icon)(\\s*\\()(\\s*[!-$\\&'*-/;-?\\\\^\\w\\s]*)(\\s*\\))"
|
|
1124
|
+
},
|
|
1125
|
+
{
|
|
1126
|
+
"captures": {
|
|
1127
|
+
"1": {
|
|
1128
|
+
"name": "variable"
|
|
1129
|
+
},
|
|
1130
|
+
"2": {
|
|
1131
|
+
"name": "keyword.control.mermaid"
|
|
1132
|
+
},
|
|
1133
|
+
"3": {
|
|
1134
|
+
"name": "string"
|
|
1135
|
+
},
|
|
1136
|
+
"4": {
|
|
1137
|
+
"name": "keyword.control.mermaid"
|
|
1138
|
+
}
|
|
1139
|
+
},
|
|
1140
|
+
"match": "(?i)(\\s*[!-$\\&'*-/:-?\\\\^\\w\\s]*)(\\s*\\({1,2}|\\){1,2}|\\{\\{|\\[)(\\s*[!-$\\&'*-/:-?\\\\^\\w\\s]*)(\\s*\\){1,2}|\\({1,2}|}}|])"
|
|
1141
|
+
},
|
|
1142
|
+
{
|
|
1143
|
+
"match": "^(\\s*[!-$\\&'*-/:-?\\\\^\\w\\s]*)",
|
|
1144
|
+
"name": "string"
|
|
1145
|
+
}
|
|
1146
|
+
]
|
|
1147
|
+
},
|
|
1084
1148
|
{
|
|
1085
1149
|
"begin": "^\\s*(pie)",
|
|
1086
1150
|
"beginCaptures": {
|
|
@@ -2001,7 +2065,7 @@
|
|
|
2001
2065
|
]
|
|
2002
2066
|
},
|
|
2003
2067
|
"mermaid-code-block": {
|
|
2004
|
-
"begin": "(?i)(?<=[`~])mermaid(\\s+[^`~]*)?$",
|
|
2068
|
+
"begin": "(?i)(?<=[`~])\\s*mermaid(\\s+[^`~]*)?$",
|
|
2005
2069
|
"contentName": "meta.embedded.block.mermaid",
|
|
2006
2070
|
"end": "(^|\\G)(?=\\s*[`~]{3,}\\s*$)",
|
|
2007
2071
|
"patterns": [
|
|
@@ -2011,7 +2075,7 @@
|
|
|
2011
2075
|
]
|
|
2012
2076
|
},
|
|
2013
2077
|
"mermaid-code-block-with-attributes": {
|
|
2014
|
-
"begin": "(?i)(?<=[`~])\\{\\s*\\.?mermaid(\\s+[^`~]*)?$",
|
|
2078
|
+
"begin": "(?i)(?<=[`~])\\s*\\{\\s*\\.?mermaid(\\s+[^`~]*)?$",
|
|
2015
2079
|
"contentName": "meta.embedded.block.mermaid",
|
|
2016
2080
|
"end": "(^|\\G)(?=\\s*[`~]{3,}\\s*$)",
|
|
2017
2081
|
"patterns": [
|
package/grammars/mojo.json
CHANGED
|
@@ -0,0 +1,393 @@
|
|
|
1
|
+
{
|
|
2
|
+
"displayName": "MoonBit",
|
|
3
|
+
"fileTypes": [
|
|
4
|
+
"mbt"
|
|
5
|
+
],
|
|
6
|
+
"name": "moonbit",
|
|
7
|
+
"patterns": [
|
|
8
|
+
{
|
|
9
|
+
"include": "#strings"
|
|
10
|
+
},
|
|
11
|
+
{
|
|
12
|
+
"include": "#comments"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"include": "#constants"
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"include": "#keywords"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"include": "#functions"
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"include": "#support"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"include": "#attribute"
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"include": "#types"
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"include": "#modules"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"include": "#variables"
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
"repository": {
|
|
40
|
+
"attribute": {
|
|
41
|
+
"patterns": [
|
|
42
|
+
{
|
|
43
|
+
"captures": {
|
|
44
|
+
"1": {
|
|
45
|
+
"name": "keyword.control.directive"
|
|
46
|
+
},
|
|
47
|
+
"2": {
|
|
48
|
+
"patterns": [
|
|
49
|
+
{
|
|
50
|
+
"include": "#strings"
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"match": "[ .0-9A-Z_a-z]+",
|
|
54
|
+
"name": "entity.name.tag"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"match": "=",
|
|
58
|
+
"name": "keyword.operator.attribute.moonbit"
|
|
59
|
+
}
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
"match": "(#[a-z][ .0-9A-Z_a-z]*)(.*)"
|
|
64
|
+
}
|
|
65
|
+
]
|
|
66
|
+
},
|
|
67
|
+
"comments": {
|
|
68
|
+
"patterns": [
|
|
69
|
+
{
|
|
70
|
+
"match": "//[^/].*",
|
|
71
|
+
"name": "comment.line"
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"begin": "///",
|
|
75
|
+
"name": "comment.block.documentation.moonbit",
|
|
76
|
+
"patterns": [
|
|
77
|
+
{
|
|
78
|
+
"begin": "\\s*```",
|
|
79
|
+
"beginCaptures": {
|
|
80
|
+
"0": {
|
|
81
|
+
"name": "markup.fenced_code.block.markdown"
|
|
82
|
+
}
|
|
83
|
+
},
|
|
84
|
+
"end": "\\s*```",
|
|
85
|
+
"endCaptures": {
|
|
86
|
+
"0": {
|
|
87
|
+
"name": "markup.fenced_code.block.markdown"
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
"name": "meta.embedded.line.moonbit",
|
|
91
|
+
"patterns": [
|
|
92
|
+
{
|
|
93
|
+
"include": "$self"
|
|
94
|
+
}
|
|
95
|
+
]
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"match": ".*",
|
|
99
|
+
"name": "comment.block.documentation.moonbit"
|
|
100
|
+
}
|
|
101
|
+
],
|
|
102
|
+
"while": "///"
|
|
103
|
+
}
|
|
104
|
+
]
|
|
105
|
+
},
|
|
106
|
+
"constants": {
|
|
107
|
+
"patterns": [
|
|
108
|
+
{
|
|
109
|
+
"match": "\\b\\d([_\\d])*(?!\\.)((U)?(L)?|N?)\\b",
|
|
110
|
+
"name": "constant.numeric.moonbit"
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
"match": "(?<=\\.)\\d((?=\\.)|\\b)",
|
|
114
|
+
"name": "constant.numeric.moonbit"
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
"match": "\\b\\d+(?=\\.\\.)",
|
|
118
|
+
"name": "constant.numeric.moonbit"
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
"match": "\\b\\d[_\\d]*\\.[_\\d]*([Ee][-+]?\\d[_\\d]*\\b)?",
|
|
122
|
+
"name": "constant.numeric.moonbit"
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
"match": "\\b0[Oo][0-7][0-7]*((U)?(L)?|N?)\\b",
|
|
126
|
+
"name": "constant.numeric.moonbit"
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
"match": "\\b0[Xx][A-Fa-f\\d][A-F_a-f\\d]*(([LU]|UL|N)\\b|\\.[A-F_a-f\\d]*([Pp][-+]?[A-F_a-f\\d]+\\b)?)?",
|
|
130
|
+
"name": "constant.numeric.moonbit"
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
"match": "\\b(true|false)\\b",
|
|
134
|
+
"name": "constant.language.moonbit"
|
|
135
|
+
}
|
|
136
|
+
]
|
|
137
|
+
},
|
|
138
|
+
"escape": {
|
|
139
|
+
"patterns": [
|
|
140
|
+
{
|
|
141
|
+
"match": "\\\\[\"'0\\\\bnrt]",
|
|
142
|
+
"name": "constant.character.escape.moonbit"
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
"match": "\\\\x\\h{2}",
|
|
146
|
+
"name": "constant.character.escape.moonbit"
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
"match": "\\\\o[0-3][0-7]{2}",
|
|
150
|
+
"name": "constant.character.escape.moonbit"
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"match": "\\\\u\\h{4}",
|
|
154
|
+
"name": "constant.character.escape.unicode.moonbit"
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
"match": "\\\\u\\{\\h*}",
|
|
158
|
+
"name": "constant.character.escape.unicode.moonbit"
|
|
159
|
+
}
|
|
160
|
+
]
|
|
161
|
+
},
|
|
162
|
+
"functions": {
|
|
163
|
+
"patterns": [
|
|
164
|
+
{
|
|
165
|
+
"captures": {
|
|
166
|
+
"1": {
|
|
167
|
+
"name": "keyword.moonbit"
|
|
168
|
+
},
|
|
169
|
+
"2": {
|
|
170
|
+
"name": "entity.name.type.moonbit"
|
|
171
|
+
},
|
|
172
|
+
"3": {
|
|
173
|
+
"name": "entity.name.function.moonbit"
|
|
174
|
+
}
|
|
175
|
+
},
|
|
176
|
+
"match": "\\b(fn)\\b\\s*(?:([A-Z][0-9A-Z_a-z]*)::)?([0-9_a-z][0-9A-Z_a-z]*)?\\b"
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
"begin": "(?!\\bfn\\s+)(?:\\.|::)?([0-9_a-z][0-9A-Z_a-z]*([!?]|!!)?)\\s*(\\()",
|
|
180
|
+
"beginCaptures": {
|
|
181
|
+
"1": {
|
|
182
|
+
"name": "entity.name.function.moonbit"
|
|
183
|
+
},
|
|
184
|
+
"2": {
|
|
185
|
+
"name": "punctuation.brackets.round.moonbit"
|
|
186
|
+
}
|
|
187
|
+
},
|
|
188
|
+
"end": "\\)",
|
|
189
|
+
"endCaptures": {
|
|
190
|
+
"0": {
|
|
191
|
+
"name": "punctuation.brackets.round.moonbit"
|
|
192
|
+
}
|
|
193
|
+
},
|
|
194
|
+
"name": "meta.function.call.moonbit",
|
|
195
|
+
"patterns": [
|
|
196
|
+
{
|
|
197
|
+
"include": "#comments"
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
"include": "#constants"
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
"include": "#keywords"
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
"include": "#functions"
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
"include": "#support"
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
"include": "#types"
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
"include": "#modules"
|
|
216
|
+
},
|
|
217
|
+
{
|
|
218
|
+
"include": "#strings"
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
"include": "#variables"
|
|
222
|
+
}
|
|
223
|
+
]
|
|
224
|
+
}
|
|
225
|
+
]
|
|
226
|
+
},
|
|
227
|
+
"interpolation": {
|
|
228
|
+
"patterns": [
|
|
229
|
+
{
|
|
230
|
+
"begin": "\\\\\\{",
|
|
231
|
+
"beginCaptures": {
|
|
232
|
+
"0": {
|
|
233
|
+
"name": "punctuation.section.embedded.begin.moonbit"
|
|
234
|
+
}
|
|
235
|
+
},
|
|
236
|
+
"contentName": "source.moonbit",
|
|
237
|
+
"end": "}",
|
|
238
|
+
"endCaptures": {
|
|
239
|
+
"0": {
|
|
240
|
+
"name": "punctuation.section.embedded.end.moonbit"
|
|
241
|
+
}
|
|
242
|
+
},
|
|
243
|
+
"name": "meta.embedded.line.moonbit",
|
|
244
|
+
"patterns": [
|
|
245
|
+
{
|
|
246
|
+
"include": "$self"
|
|
247
|
+
}
|
|
248
|
+
]
|
|
249
|
+
}
|
|
250
|
+
]
|
|
251
|
+
},
|
|
252
|
+
"keywords": {
|
|
253
|
+
"patterns": [
|
|
254
|
+
{
|
|
255
|
+
"match": "\\b(async)\\b",
|
|
256
|
+
"name": "keyword.control.moonbit.async"
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
"match": "\\b(guard|if|while|break|continue|return|try|catch|except|raise|noraise|match|lexmatch|using|else|as|in|is|loop|for|async|defer)\\b",
|
|
260
|
+
"name": "keyword.control.moonbit"
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
"match": "\\b(type!|lexmatch\\?|(type|typealias|let|const|enum|struct|import|trait|traitalias|derive|test|impl|with|fnalias|recur|suberror|letrec|and)\\b)",
|
|
264
|
+
"name": "keyword.moonbit"
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
"match": "\\b(mut|pub|priv|readonly|extern)\\b",
|
|
268
|
+
"name": "storage.modifier.moonbit"
|
|
269
|
+
},
|
|
270
|
+
{
|
|
271
|
+
"match": "->",
|
|
272
|
+
"name": "storage.type.function.arrow.moonbit"
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
"match": "=>",
|
|
276
|
+
"name": "storage.type.function.arrow.moonbit"
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
"match": "=",
|
|
280
|
+
"name": "keyword.operator.assignment.moonbit"
|
|
281
|
+
},
|
|
282
|
+
{
|
|
283
|
+
"match": "\\|>",
|
|
284
|
+
"name": "keyword.operator.other.moonbit"
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
"match": "(===?|!=|>=|<=|(?<!-)(?<!\\|)>(?!>)|<(?!<))",
|
|
288
|
+
"name": "keyword.operator.comparison.moonbit"
|
|
289
|
+
},
|
|
290
|
+
{
|
|
291
|
+
"match": "(\\bnot\\b|&&|\\|\\|)",
|
|
292
|
+
"name": "keyword.operator.logical.moonbit"
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
"match": "(\\|(?!\\|)(?!>)|&(?!&)|\\^|<<|>>)",
|
|
296
|
+
"name": "keyword.operator.bitwise.moonbit"
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"match": "(\\+|-(?!>)|[%*/])",
|
|
300
|
+
"name": "keyword.operator.math.moonbit"
|
|
301
|
+
}
|
|
302
|
+
]
|
|
303
|
+
},
|
|
304
|
+
"modules": {
|
|
305
|
+
"patterns": [
|
|
306
|
+
{
|
|
307
|
+
"match": "@[A-Za-z][/-9A-Z_a-z]*",
|
|
308
|
+
"name": "entity.name.namespace.moonbit"
|
|
309
|
+
}
|
|
310
|
+
]
|
|
311
|
+
},
|
|
312
|
+
"strings": {
|
|
313
|
+
"patterns": [
|
|
314
|
+
{
|
|
315
|
+
"captures": {
|
|
316
|
+
"1": {
|
|
317
|
+
"name": "keyword.operator.other.moonbit"
|
|
318
|
+
}
|
|
319
|
+
},
|
|
320
|
+
"match": "(#\\|).*",
|
|
321
|
+
"name": "string.line"
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
"captures": {
|
|
325
|
+
"1": {
|
|
326
|
+
"name": "keyword.operator.other.moonbit"
|
|
327
|
+
},
|
|
328
|
+
"2": {
|
|
329
|
+
"patterns": [
|
|
330
|
+
{
|
|
331
|
+
"include": "#escape"
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
"include": "#interpolation"
|
|
335
|
+
}
|
|
336
|
+
]
|
|
337
|
+
}
|
|
338
|
+
},
|
|
339
|
+
"match": "(\\$\\|)(.*)",
|
|
340
|
+
"name": "string.line"
|
|
341
|
+
},
|
|
342
|
+
{
|
|
343
|
+
"begin": "'",
|
|
344
|
+
"end": "'",
|
|
345
|
+
"name": "string.quoted.single.moonbit",
|
|
346
|
+
"patterns": [
|
|
347
|
+
{
|
|
348
|
+
"include": "#escape"
|
|
349
|
+
}
|
|
350
|
+
]
|
|
351
|
+
},
|
|
352
|
+
{
|
|
353
|
+
"begin": "\"",
|
|
354
|
+
"end": "\"",
|
|
355
|
+
"name": "string.quoted.double.moonbit",
|
|
356
|
+
"patterns": [
|
|
357
|
+
{
|
|
358
|
+
"include": "#escape"
|
|
359
|
+
},
|
|
360
|
+
{
|
|
361
|
+
"include": "#interpolation"
|
|
362
|
+
}
|
|
363
|
+
]
|
|
364
|
+
}
|
|
365
|
+
]
|
|
366
|
+
},
|
|
367
|
+
"support": {
|
|
368
|
+
"patterns": [
|
|
369
|
+
{
|
|
370
|
+
"match": "\\b(Eq|Compare|Hash|Show|Default|ToJson|FromJson)\\b",
|
|
371
|
+
"name": "support.class.moonbit"
|
|
372
|
+
}
|
|
373
|
+
]
|
|
374
|
+
},
|
|
375
|
+
"types": {
|
|
376
|
+
"patterns": [
|
|
377
|
+
{
|
|
378
|
+
"match": "\\b(?<!@)[A-Z][0-9A-Z_a-z]*((\\?)+|\\b)",
|
|
379
|
+
"name": "entity.name.type.moonbit"
|
|
380
|
+
}
|
|
381
|
+
]
|
|
382
|
+
},
|
|
383
|
+
"variables": {
|
|
384
|
+
"patterns": [
|
|
385
|
+
{
|
|
386
|
+
"match": "\\b(?<!\\.|::)[_a-z][0-9A-Z_a-z]*\\b",
|
|
387
|
+
"name": "variable.other.moonbit"
|
|
388
|
+
}
|
|
389
|
+
]
|
|
390
|
+
}
|
|
391
|
+
},
|
|
392
|
+
"scopeName": "source.moonbit"
|
|
393
|
+
}
|
package/grammars/nextflow.json
CHANGED
|
@@ -177,6 +177,9 @@
|
|
|
177
177
|
},
|
|
178
178
|
"nextflow": {
|
|
179
179
|
"patterns": [
|
|
180
|
+
{
|
|
181
|
+
"include": "#record-def"
|
|
182
|
+
},
|
|
180
183
|
{
|
|
181
184
|
"include": "#enum-def"
|
|
182
185
|
},
|
|
@@ -266,6 +269,24 @@
|
|
|
266
269
|
}
|
|
267
270
|
]
|
|
268
271
|
},
|
|
272
|
+
"record-def": {
|
|
273
|
+
"begin": "^\\s*(record)\\s+(\\w+)\\s*\\{",
|
|
274
|
+
"beginCaptures": {
|
|
275
|
+
"1": {
|
|
276
|
+
"name": "keyword.nextflow"
|
|
277
|
+
},
|
|
278
|
+
"2": {
|
|
279
|
+
"name": "storage.type.groovy"
|
|
280
|
+
}
|
|
281
|
+
},
|
|
282
|
+
"end": "}",
|
|
283
|
+
"name": "record.nextflow",
|
|
284
|
+
"patterns": [
|
|
285
|
+
{
|
|
286
|
+
"include": "source.nextflow-groovy#groovy"
|
|
287
|
+
}
|
|
288
|
+
]
|
|
289
|
+
},
|
|
269
290
|
"workflow-body": {
|
|
270
291
|
"patterns": [
|
|
271
292
|
{
|