Skip to content

Commit d5bded0

Browse files
committed
update grammars
1 parent 086a751 commit d5bded0

9 files changed

Lines changed: 101 additions & 46 deletions

File tree

extensions/bat/syntaxes/batchfile.tmLanguage.json

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
55
"Once accepted there, we are happy to receive an update request."
66
],
7-
"version": "https://github.com/mmims/language-batchfile/commit/3dd105c31484e5975144478dac1aa91d8f51e528",
7+
"version": "https://github.com/mmims/language-batchfile/commit/9b2d868a43d6a04a4dc27cb31f907b960a4fdab1",
88
"name": "Batch File",
99
"scopeName": "source.batchfile",
1010
"patterns": [
@@ -110,7 +110,7 @@
110110
"include": "#parens"
111111
},
112112
{
113-
"begin": "(\")\\s*([^ ][^=]*)(=)\"?",
113+
"begin": "(\")\\s*([^ ][^=]*)(=)",
114114
"beginCaptures": {
115115
"1": {
116116
"name": "punctuation.definition.string.begin.batchfile"
@@ -125,9 +125,10 @@
125125
"end": "\"",
126126
"endCaptures": {
127127
"0": {
128-
"name": "string.quoted.double.batchfile"
128+
"name": "punctuation.definition.string.end.batchfile"
129129
}
130130
},
131+
"name": "string.quoted.double.batchfile",
131132
"patterns": [
132133
{
133134
"include": "#variables"
@@ -493,6 +494,10 @@
493494
},
494495
"name": "string.quoted.double.batchfile",
495496
"patterns": [
497+
{
498+
"match": "%%",
499+
"name": "constant.character.escape.batchfile"
500+
},
496501
{
497502
"include": "#variables"
498503
}
@@ -507,9 +512,11 @@
507512
"captures": {
508513
"1": {
509514
"name": "punctuation.definition.variable.batchfile"
515+
},
516+
"2": {
517+
"name": "variable.parameter.batchfile"
510518
}
511-
},
512-
"name": "variable.parameter.batchfile"
519+
}
513520
},
514521
{
515522
"include": "#variable"

extensions/bat/test/colorize-results/test_bat.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -89,13 +89,13 @@
8989
},
9090
{
9191
"c": "%",
92-
"t": "source.batchfile variable.parameter.batchfile punctuation.definition.variable.batchfile",
92+
"t": "source.batchfile punctuation.definition.variable.batchfile",
9393
"r": {
94-
"dark_plus": "variable: #9CDCFE",
95-
"light_plus": "variable: #001080",
94+
"dark_plus": "default: #D4D4D4",
95+
"light_plus": "default: #000000",
9696
"dark_vs": "default: #D4D4D4",
9797
"light_vs": "default: #000000",
98-
"hc_black": "variable: #9CDCFE"
98+
"hc_black": "default: #FFFFFF"
9999
}
100100
},
101101
{

extensions/java/syntaxes/java.tmLanguage.json

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
55
"Once accepted there, we are happy to receive an update request."
66
],
7-
"version": "https://github.com/atom/language-java/commit/5c2863da1425d61914d2e04ef31b86f8c5883c5f",
7+
"version": "https://github.com/atom/language-java/commit/bbbd3236c0ef9a9cd8c59d6ad4bd6b9b231dc714",
88
"name": "Java",
99
"scopeName": "source.java",
1010
"patterns": [
@@ -769,7 +769,7 @@
769769
"name": "storage.modifier.$1.java"
770770
},
771771
{
772-
"match": "([a-zA-Z$_][a-zA-Z0-9$_]*)(?=\\s*<)",
772+
"match": "(?<!\\.)([a-zA-Z$_][a-zA-Z0-9$_]*)(?=\\s*<)",
773773
"captures": {
774774
"1": {
775775
"name": "storage.type.java"
@@ -795,6 +795,10 @@
795795
"match": ",",
796796
"name": "punctuation.separator.delimiter.java"
797797
},
798+
{
799+
"match": "\\.",
800+
"name": "punctuation.separator.period.java"
801+
},
798802
{
799803
"include": "#parens"
800804
},
@@ -923,6 +927,10 @@
923927
{
924928
"match": "(\\||&)",
925929
"name": "keyword.operator.bitwise.java"
930+
},
931+
{
932+
"match": "\\b(const|goto)\\b",
933+
"name": "keyword.reserved.java"
926934
}
927935
]
928936
},
@@ -1104,7 +1112,7 @@
11041112
]
11051113
},
11061114
{
1107-
"match": "\\b(?:[A-Z]\\w*\\s*(\\.)\\s*)*[A-Z]\\w*\\b",
1115+
"match": "\\b(?:[A-Z]\\w*\\s*(\\.)\\s*)*[A-Z]\\w*\\b((?=\\s*[A-Za-z$_\\n])|(?=\\s*\\.\\.\\.))",
11081116
"name": "storage.type.java",
11091117
"captures": {
11101118
"1": {
@@ -1160,6 +1168,10 @@
11601168
{
11611169
"match": ",",
11621170
"name": "punctuation.separator.delimiter.java"
1171+
},
1172+
{
1173+
"match": "\\.\\.\\.",
1174+
"name": "punctuation.definition.parameters.varargs.java"
11631175
}
11641176
]
11651177
},
@@ -1352,7 +1364,7 @@
13521364
]
13531365
},
13541366
"variables": {
1355-
"begin": "(?x)\n(?=\n (\n (void|boolean|byte|char|short|int|float|long|double)\n |\n (?>(\\w+\\.)*[A-Z]+\\w*) # e.g. `javax.ws.rs.Response`, or `String`\n )\n (\n <[\\w<>,?\\s]*> # HashMap<Integer, String>\n )?\n (\n (\\[\\])* # int[][]\n )?\n \\s+\n [A-Za-z_$][\\w$]* # At least one identifier after space\n ([\\w\\[\\],$][\\w\\[\\],\\s]*)? # possibly primitive array or additional identifiers\n \\s*(=|;)\n)",
1367+
"begin": "(?x)\n(?=\n (\n (void|boolean|byte|char|short|int|float|long|double)\n |\n (?>(\\w+\\.)*[A-Z]+\\w*) # e.g. `javax.ws.rs.Response`, or `String`\n )\n (\n <[\\w<>,\\.?\\s]*> # e.g. `HashMap<Integer, String>`, or `List<java.lang.String>`\n )?\n (\n (\\[\\])* # int[][]\n )?\n \\s+\n [A-Za-z_$][\\w$]* # At least one identifier after space\n ([\\w\\[\\],$][\\w\\[\\],\\s]*)? # possibly primitive array or additional identifiers\n \\s*(=|;)\n)",
13561368
"end": "(?=;)",
13571369
"name": "meta.definition.variable.java",
13581370
"patterns": [

extensions/javascript/syntaxes/JavaScript.tmLanguage.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
55
"Once accepted there, we are happy to receive an update request."
66
],
7-
"version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/b61fd56a52f6b85598eda2f3842dfb7447d0d4eb",
7+
"version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/4ef3570784b60450d6baac681cb096fbf1d2397e",
88
"name": "JavaScript (with React support)",
99
"scopeName": "source.js",
1010
"patterns": [
@@ -3243,6 +3243,10 @@
32433243
{
32443244
"name": "keyword.operator.expression.infer.js",
32453245
"match": "(?<![_$[:alnum:]])(?:(?<=\\.\\.\\.)|(?<!\\.))infer(?=\\s+[_$[:alpha:]])"
3246+
},
3247+
{
3248+
"name": "keyword.operator.expression.import.js",
3249+
"match": "(?<![_$[:alnum:]])(?:(?<=\\.\\.\\.)|(?<!\\.))import(?=\\s*\\()"
32463250
}
32473251
]
32483252
},

extensions/javascript/syntaxes/JavaScriptReact.tmLanguage.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
55
"Once accepted there, we are happy to receive an update request."
66
],
7-
"version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/b61fd56a52f6b85598eda2f3842dfb7447d0d4eb",
7+
"version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/4ef3570784b60450d6baac681cb096fbf1d2397e",
88
"name": "JavaScript (with React support)",
99
"scopeName": "source.js.jsx",
1010
"patterns": [
@@ -3243,6 +3243,10 @@
32433243
{
32443244
"name": "keyword.operator.expression.infer.js.jsx",
32453245
"match": "(?<![_$[:alnum:]])(?:(?<=\\.\\.\\.)|(?<!\\.))infer(?=\\s+[_$[:alpha:]])"
3246+
},
3247+
{
3248+
"name": "keyword.operator.expression.import.js.jsx",
3249+
"match": "(?<![_$[:alnum:]])(?:(?<=\\.\\.\\.)|(?<!\\.))import(?=\\s*\\()"
32463250
}
32473251
]
32483252
},

extensions/perl/syntaxes/perl.tmLanguage.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
55
"Once accepted there, we are happy to receive an update request."
66
],
7-
"version": "https://github.com/textmate/perl.tmbundle/commit/c0b7a4bd65882380522d82a60b536479a62b07c3",
7+
"version": "https://github.com/textmate/perl.tmbundle/commit/80826abe75250286c2a1a07958e50e8551d3f50c",
88
"name": "Perl",
99
"scopeName": "source.perl",
1010
"comment": "\n\tTODO:\tInclude RegExp syntax\n",
@@ -332,7 +332,7 @@
332332
]
333333
},
334334
{
335-
"begin": "(?<!\\{|\\+|\\-)(m)(?!_)\\s*([^\\sa-zA-Z0-9'\\{\\[\\(\\<])",
335+
"begin": "\\G(?<!\\{|\\+|\\-)(m)(?!_)\\s*([^\\sa-zA-Z0-9'\\{\\[\\(\\<])",
336336
"captures": {
337337
"0": {
338338
"name": "punctuation.definition.string.perl"

extensions/php/syntaxes/php.tmLanguage.json

Lines changed: 47 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
55
"Once accepted there, we are happy to receive an update request."
66
],
7-
"version": "https://github.com/atom/language-php/commit/11b2057dbf32355019621ee3769f5c8ef577f524",
7+
"version": "https://github.com/atom/language-php/commit/b054176835218c446d22b3c1b9dcfdcf8cacf49f",
88
"scopeName": "source.php",
99
"patterns": [
1010
{
@@ -230,7 +230,7 @@
230230
]
231231
},
232232
{
233-
"begin": "(?i)^\\s*(?:(abstract|final)\\s+)?(class)\\s+([a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*)",
233+
"begin": "(?i)(?:^|(?<=}))\\s*(?:(abstract|final)\\s+)?(class)\\s+([a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*)",
234234
"beginCaptures": {
235235
"1": {
236236
"name": "storage.modifier.${1:/downcase}.php"
@@ -355,7 +355,15 @@
355355
"include": "#switch_statement"
356356
},
357357
{
358-
"match": "(?x)\n\\s*\n\\b(\n break|case|continue|declare|default|die|do|\n else(if)?|end(declare|for(each)?|if|switch|while)|exit|\n for(each)?|if|return|switch|use|while|yield\n)\\b",
358+
"match": "\\s*\\b(yield\\s+from)\\b",
359+
"captures": {
360+
"1": {
361+
"name": "keyword.control.yield-from.php"
362+
}
363+
}
364+
},
365+
{
366+
"match": "(?x)\n\\s* # FIXME: Removing this causes specs to fail. Investigate.\n\\b(\n break|case|continue|declare|default|die|do|\n else(if)?|end(declare|for(each)?|if|switch|while)|exit|\n for(each)?|if|return|switch|use|while|yield\n)\\b",
359367
"captures": {
360368
"1": {
361369
"name": "keyword.control.${1:/downcase}.php"
@@ -521,7 +529,7 @@
521529
}
522530
},
523531
"contentName": "meta.function.parameters.php",
524-
"end": "(\\))(?:\\s*(:)\\s*([a-zA-Z_\\x{7f}-\\x{7fffffff}][a-zA-Z0-9_\\x{7f}-\\x{7fffffff}]*))?",
532+
"end": "(\\))(?:\\s*(:)\\s*(\\?)?\\s*([a-zA-Z_\\x{7f}-\\x{7fffffff}][a-zA-Z0-9_\\x{7f}-\\x{7fffffff}]*))?",
525533
"endCaptures": {
526534
"1": {
527535
"name": "punctuation.definition.parameters.end.bracket.round.php"
@@ -530,6 +538,9 @@
530538
"name": "keyword.operator.return-value.php"
531539
},
532540
"3": {
541+
"name": "keyword.operator.nullable-type.php"
542+
},
543+
"4": {
533544
"name": "storage.type.php"
534545
}
535546
},
@@ -989,27 +1000,30 @@
9891000
"name": "punctuation.separator.delimiter.php"
9901001
},
9911002
{
992-
"begin": "(?xi)\n(array) # Typehint\n\\s+((&)?\\s*(\\$+)[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Variable name with possible reference\n\\s*(=)\\s*(array)\\s*(\\() # Default value",
1003+
"begin": "(?xi)\n(?:(\\?)\\s*)?(array) # Typehint\n\\s+((&)?\\s*(\\$+)[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Variable name with possible reference\n\\s*(=)\\s*(array)\\s*(\\() # Default value",
9931004
"beginCaptures": {
9941005
"1": {
995-
"name": "storage.type.php"
1006+
"name": "keyword.operator.nullable-type.php"
9961007
},
9971008
"2": {
998-
"name": "variable.other.php"
1009+
"name": "storage.type.php"
9991010
},
10001011
"3": {
1001-
"name": "storage.modifier.reference.php"
1012+
"name": "variable.other.php"
10021013
},
10031014
"4": {
1004-
"name": "punctuation.definition.variable.php"
1015+
"name": "storage.modifier.reference.php"
10051016
},
10061017
"5": {
1007-
"name": "keyword.operator.assignment.php"
1018+
"name": "punctuation.definition.variable.php"
10081019
},
10091020
"6": {
1010-
"name": "support.function.construct.php"
1021+
"name": "keyword.operator.assignment.php"
10111022
},
10121023
"7": {
1024+
"name": "support.function.construct.php"
1025+
},
1026+
"8": {
10131027
"name": "punctuation.definition.array.begin.bracket.round.php"
10141028
}
10151029
},
@@ -1034,49 +1048,55 @@
10341048
]
10351049
},
10361050
{
1037-
"match": "(?xi)\n(array|callable) # Typehint\n\\s+((&)?\\s*(\\$+)[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Variable name with possible reference\n(?: # Optional default value\n \\s*(=)\\s*\n (?:\n (null)\n |\n (\\[)((?>[^\\[\\]]+|\\[\\g<8>\\])*)(\\])\n |((?:\\S*?\\(\\))|(?:\\S*?))\n )\n)?\n\\s*(?=,|\\)|/[/*]|\\#|$) # A closing parentheses (end of argument list) or a comma or a comment",
1051+
"match": "(?xi)\n(?:(\\?)\\s*)?(array|callable) # Typehint\n\\s+((&)?\\s*(\\$+)[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Variable name with possible reference\n(?: # Optional default value\n \\s*(=)\\s*\n (?:\n (null)\n |\n (\\[)((?>[^\\[\\]]+|\\[\\g<8>\\])*)(\\])\n |((?:\\S*?\\(\\))|(?:\\S*?))\n )\n)?\n\\s*(?=,|\\)|/[/*]|\\#|$) # A closing parentheses (end of argument list) or a comma or a comment",
10381052
"name": "meta.function.parameter.array.php",
10391053
"captures": {
10401054
"1": {
1041-
"name": "storage.type.php"
1055+
"name": "keyword.operator.nullable-type.php"
10421056
},
10431057
"2": {
1044-
"name": "variable.other.php"
1058+
"name": "storage.type.php"
10451059
},
10461060
"3": {
1047-
"name": "storage.modifier.reference.php"
1061+
"name": "variable.other.php"
10481062
},
10491063
"4": {
1050-
"name": "punctuation.definition.variable.php"
1064+
"name": "storage.modifier.reference.php"
10511065
},
10521066
"5": {
1053-
"name": "keyword.operator.assignment.php"
1067+
"name": "punctuation.definition.variable.php"
10541068
},
10551069
"6": {
1056-
"name": "constant.language.php"
1070+
"name": "keyword.operator.assignment.php"
10571071
},
10581072
"7": {
1059-
"name": "punctuation.section.array.begin.php"
1073+
"name": "constant.language.php"
10601074
},
10611075
"8": {
1076+
"name": "punctuation.section.array.begin.php"
1077+
},
1078+
"9": {
10621079
"patterns": [
10631080
{
10641081
"include": "#parameter-default-types"
10651082
}
10661083
]
10671084
},
1068-
"9": {
1085+
"10": {
10691086
"name": "punctuation.section.array.end.php"
10701087
},
1071-
"10": {
1088+
"11": {
10721089
"name": "invalid.illegal.non-null-typehinted.php"
10731090
}
10741091
}
10751092
},
10761093
{
1077-
"begin": "(?xi)\n(\\\\?(?:[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*\\\\)*) # Optional namespace\n([a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Typehinted class name\n\\s+((&)?\\s*(\\.\\.\\.)?(\\$+)[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Variable name with possible reference",
1094+
"begin": "(?xi)\n(?:(\\?)\\s*)?\n(\\\\?(?:[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*\\\\)*) # Optional namespace\n([a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Typehinted class name\n\\s+((&)?\\s*(\\.\\.\\.)?(\\$+)[a-z_\\x{7f}-\\x{7fffffff}][a-z0-9_\\x{7f}-\\x{7fffffff}]*) # Variable name with possible reference",
10781095
"beginCaptures": {
10791096
"1": {
1097+
"name": "keyword.operator.nullable-type.php"
1098+
},
1099+
"2": {
10801100
"name": "support.other.namespace.php",
10811101
"patterns": [
10821102
{
@@ -1089,19 +1109,19 @@
10891109
}
10901110
]
10911111
},
1092-
"2": {
1112+
"3": {
10931113
"name": "storage.type.php"
10941114
},
1095-
"3": {
1115+
"4": {
10961116
"name": "variable.other.php"
10971117
},
1098-
"4": {
1118+
"5": {
10991119
"name": "storage.modifier.reference.php"
11001120
},
1101-
"5": {
1121+
"6": {
11021122
"name": "keyword.operator.variadic.php"
11031123
},
1104-
"6": {
1124+
"7": {
11051125
"name": "punctuation.definition.variable.php"
11061126
}
11071127
},

0 commit comments

Comments
 (0)