Skip to content

Commit 0acef69

Browse files
committed
feat: update language pack grammars
1 parent 6bccc03 commit 0acef69

14 files changed

+1841
-681
lines changed

org.eclipse.tm4e.language_pack/README.md

+60-60
Large diffs are not rendered by default.

org.eclipse.tm4e.language_pack/about.html

+60-60
Large diffs are not rendered by default.

org.eclipse.tm4e.language_pack/syntaxes/csharp/csharp.tmLanguage.json

+2-2
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/dotnet/csharp-tmLanguage/commit/d63e2661d4e0c83b6c7810eb1d0eedc5da843b04",
7+
"version": "https://github.com/dotnet/csharp-tmLanguage/commit/62026a70f9fcc42d9222eccfec34ed5ee0784f3d",
88
"name": "C#",
99
"scopeName": "source.cs",
1010
"patterns": [
@@ -4206,7 +4206,7 @@
42064206
]
42074207
},
42084208
"invocation-expression": {
4209-
"begin": "(?x)\n(?:\n (?:(\\?)\\s*)? # preceding null-conditional operator?\n (\\.)\\s*| # preceding dot?\n (->)\\s* # preceding pointer arrow?\n)?\n(@?[_[:alpha:]][_[:alnum:]]*)\\s* # method name\n(\n <\n (?<type_args>\n [^<>()]++|\n <\\g<type_args>*+>|\n \\(\\g<type_args>*+\\)\n )*+\n >\\s*\n)? # type arguments\n(?=\\() # open paren of argument list",
4209+
"begin": "(?x)\n(?:\n (?:(\\?)\\s*)? # preceding null-conditional operator?\n (\\.)\\s*| # preceding dot?\n (->)\\s* # preceding pointer arrow?\n)?\n(@?[_[:alpha:]][_[:alnum:]]*)\\s* # method name\n(\n <\n (?<type_args>\n [^<>()]|\n \\((?:[^<>()]|<[^<>()]*>|\\([^<>()]*\\))*\\)|\n <\\g<type_args>*>\n )*\n >\\s*\n)? # type arguments\n(?=\\() # open paren of argument list",
42104210
"beginCaptures": {
42114211
"1": {
42124212
"name": "keyword.operator.null-conditional.cs"

org.eclipse.tm4e.language_pack/syntaxes/javascript/javascript.language-configuration.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@
231231
// Add // when pressing enter from inside line comment
232232
{
233233
"beforeText": {
234-
"pattern": "\/\/.*"
234+
"pattern": "(?<!\\w:)\/\/.*"
235235
},
236236
"afterText": {
237237
"pattern": "^(?!\\s*$).+"

org.eclipse.tm4e.language_pack/syntaxes/javascript/javascriptreact.language-configuration.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@
231231
// Add // when pressing enter from inside line comment
232232
{
233233
"beforeText": {
234-
"pattern": "\/\/.*"
234+
"pattern": "(?<!\\w:)\/\/.*"
235235
},
236236
"afterText": {
237237
"pattern": "^(?!\\s*$).+"

org.eclipse.tm4e.language_pack/syntaxes/latex/cpp_embedded_latex.tmLanguage.json

+1,494-430
Large diffs are not rendered by default.

org.eclipse.tm4e.language_pack/syntaxes/latex/latex.tmLanguage.json

+45-2
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/jlelong/vscode-latex-basics/commit/59971565a7065dbb617576c04add9d891b056319",
7+
"version": "https://github.com/jlelong/vscode-latex-basics/commit/7a35f5e0f19b28f5f1366579e2a9ad34df4f40c9",
88
"name": "LaTeX",
99
"scopeName": "text.tex.latex",
1010
"patterns": [
@@ -761,6 +761,49 @@
761761
}
762762
]
763763
},
764+
{
765+
"begin": "\\s*\\\\begin\\{(?:javacode|javaverbatim|javablock|javaconcode|javaconsole|javaconverbatim)\\*?\\}(?:\\[[a-zA-Z0-9_-]*\\])?(?=\\[|\\{|\\s*$)",
766+
"end": "\\s*\\\\end\\{(?:javacode|javaverbatim|javablock|javaconcode|javaconsole|javaconverbatim)\\*?\\}",
767+
"captures": {
768+
"0": {
769+
"patterns": [
770+
{
771+
"include": "#begin-env-tokenizer"
772+
}
773+
]
774+
}
775+
},
776+
"patterns": [
777+
{
778+
"include": "#multiline-optional-arg-no-highlight"
779+
},
780+
{
781+
"begin": "(?:\\G|(?<=\\]))(\\{)",
782+
"beginCaptures": {
783+
"1": {
784+
"name": "punctuation.definition.arguments.begin.latex"
785+
}
786+
},
787+
"end": "(\\})",
788+
"endCaptures": {
789+
"1": {
790+
"name": "punctuation.definition.arguments.end.latex"
791+
}
792+
},
793+
"contentName": "variable.parameter.function.latex"
794+
},
795+
{
796+
"begin": "^(?=\\s*)",
797+
"end": "^\\s*(?=\\\\end\\{(?:javacode|javaverbatim|javablock|javaconcode|javaconsole|javaconverbatim)\\*?\\})",
798+
"contentName": "source.java",
799+
"patterns": [
800+
{
801+
"include": "source.java"
802+
}
803+
]
804+
}
805+
]
806+
},
764807
{
765808
"begin": "\\s*\\\\begin\\{(?:jlcode|jlverbatim|jlblock|jlconcode|jlconsole|jlconverbatim)\\*?\\}(?:\\[[a-zA-Z0-9_-]*\\])?(?=\\[|\\{|\\s*$)",
766809
"end": "\\s*\\\\end\\{(?:jlcode|jlverbatim|jlblock|jlconcode|jlconsole|jlconverbatim)\\*?\\}",
@@ -1106,7 +1149,7 @@
11061149
]
11071150
},
11081151
{
1109-
"begin": "\\s*\\\\begin\\{([a-zA-Z]*code|lstlisting|minted|pyglist)\\*?\\}(?:\\[.*\\])?(?:\\{.*\\})?",
1152+
"begin": "\\s*\\\\begin\\{((?:[a-zA-Z]*code|lstlisting|minted|pyglist)\\*?)\\}(?:\\[.*\\])?(?:\\{.*\\})?",
11101153
"captures": {
11111154
"0": {
11121155
"patterns": [

org.eclipse.tm4e.language_pack/syntaxes/latex/markdown_latex_combined.tmLanguage.json

+26-6
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/jlelong/vscode-latex-basics/commit/56e2dc967e6bafafc1acfeeb80af42b8328b021a",
7+
"version": "https://github.com/jlelong/vscode-latex-basics/commit/dfa69a16a1154dbc820dc1111d72faa6954dd1e2",
88
"name": "Markdown",
99
"scopeName": "text.tex.markdown_latex_combined",
1010
"patterns": [
@@ -2483,14 +2483,34 @@
24832483
"name": "meta.separator.markdown"
24842484
},
24852485
"frontMatter": {
2486-
"begin": "\\A-{3}\\s*$",
2487-
"contentName": "meta.embedded.block.frontmatter",
2486+
"begin": "\\A(?=(-{3,}))",
2487+
"end": "^ {,3}\\1-*[ \\t]*$|^[ \\t]*\\.{3}$",
2488+
"applyEndPatternLast": 1,
2489+
"endCaptures": {
2490+
"0": {
2491+
"name": "punctuation.definition.end.frontmatter"
2492+
}
2493+
},
24882494
"patterns": [
24892495
{
2490-
"include": "source.yaml"
2496+
"begin": "\\A(-{3,})(.*)$",
2497+
"while": "^(?! {,3}\\1-*[ \\t]*$|[ \\t]*\\.{3}$)",
2498+
"beginCaptures": {
2499+
"1": {
2500+
"name": "punctuation.definition.begin.frontmatter"
2501+
},
2502+
"2": {
2503+
"name": "comment.frontmatter"
2504+
}
2505+
},
2506+
"contentName": "meta.embedded.block.frontmatter",
2507+
"patterns": [
2508+
{
2509+
"include": "source.yaml"
2510+
}
2511+
]
24912512
}
2492-
],
2493-
"end": "(^|\\G)-{3}|\\.{3}\\s*$"
2513+
]
24942514
},
24952515
"table": {
24962516
"name": "markup.table.markdown",

org.eclipse.tm4e.language_pack/syntaxes/razor/razor.tmLanguage.json

+4-1
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/dotnet/razor/commit/39159764277f3c80a786d8872eba7730da3d7ef0",
7+
"version": "https://github.com/dotnet/razor/commit/9b1e979b6c3fe7cfbe30f595b9b0994d20bd482c",
88
"name": "ASP.NET Razor",
99
"scopeName": "text.html.cshtml",
1010
"injections": {
@@ -1636,6 +1636,9 @@
16361636
{
16371637
"include": "source.cs#switch-label"
16381638
},
1639+
{
1640+
"include": "#csharp-code-block"
1641+
},
16391642
{
16401643
"include": "#razor-codeblock-body"
16411644
}

org.eclipse.tm4e.language_pack/syntaxes/swift/swift.tmLanguage.json

+45-15
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/jtbandes/swift-tmlanguage/commit/860eface4241cf9f2174d5fa690bd34389ac8d26",
7+
"version": "https://github.com/jtbandes/swift-tmlanguage/commit/b8d2889b4af1d8bad41578317a6adade642555a3",
88
"name": "Swift",
99
"scopeName": "source.swift",
1010
"comment": "See swift.tmbundle/grammar-test.swift for test cases.",
@@ -3081,7 +3081,7 @@
30813081
{
30823082
"comment": "Single-line regular expression literals must be matched all in one go\n in order to avoid ambiguities with operators, and to adhere to certain\n parsing rules in SE-0354/SE-0355, such as:\n - A regex literal will not be parsed if it contains an unbalanced ).\n - A regex may end with a space only if it began with an escaped space",
30833083
"name": "string.regexp.line.swift",
3084-
"match": "(?x)\n(((\\#+)?)/) # (1) for captures, (2) for matching end, (3) for conditionals\n(?(3)|(?!/)) # is not a comment\n(?(3)|(?!\\s)) # does not start with a space or tab\n(\\\\\\s)? # (4) may start with an escaped space or tab\n(?<guts>\n (?> # no backtracking, avoids issues with negative lookbehind at end\n (?:\n \\\\Q\n (?:(?!\\\\E)(?!/\\2).)*+\n (?:\\\\E\n # A quoted sequence may not have a closing E, in which case it extends to the end of the regex\n | (?(3)|(?<!\\s))(?=/\\2)\n )\n | \\\\.\n | \\(\\?\\#[^)]*\\)\n | \\(\\?\n # we only support a fixed maximum number of braces because otherwise we can't balance the number of open and close braces\n \\{(?<g1>\\{)?+(?<g2>\\{)?+(?<g3>\\{)?+(?<g4>\\{)?+(?<g5>\\{)?+\n .+?\n \\}(?(<g1>)\\})(?(<g2>)\\})(?(<g3>)\\})(?(<g4>)\\})(?(<g5>)\\})\n (?:\\[(?!\\d)\\w+\\])?\n [X<>]?\n \\)\n | (?<class>\\[ (?:\\\\. | [^\\[\\]] | \\g<class>)+ \\])\n | \\(\\g<guts>?+\\)\n | (?:(?!/\\2)[^()\\[\\\\])+ # any character (until end)\n )+\n )\n)?+\n# may end with a space only if it is an extended literal or contains only a single escaped space\n(?(3)|(?(5)(?<!\\s)))\n(/\\2) # (12)\n| \\#+/.+(\\n)",
3084+
"match": "(?x)\n(?!/\\s) # non-extended regex literals may not start with a space or tab\n(?!//) # disambiguation with line comments (redundant since comment rules occur earlier)\n(((\\#+)?)/) # (1) for captures, (2) for matching end, (3) for conditionals\n(\\\\\\s)? # (4) may start with an escaped space or tab\n(?<guts>\n (?> # no backtracking, avoids issues with negative lookbehind at end\n (?:\n \\\\Q\n (?:(?!\\\\E)(?!/\\2).)*+\n (?:\\\\E\n # A quoted sequence may not have a closing E, in which case it extends to the end of the regex\n | (?(3)|(?<!\\s))(?=/\\2)\n )\n | \\\\.\n | \\(\\?\\#[^)]*\\)\n | \\(\\?\n # InterpolatedCallout\n (?>(\\{(?:\\g<-1>|(?!{).*?)\\}))\n (?:\\[(?!\\d)\\w+\\])?\n [X<>]?\n \\)\n | (?<class>\\[ (?:\\\\. | [^\\[\\]] | \\g<class>)+ \\])\n | \\(\\g<guts>?+\\)\n | (?:(?!/\\2)[^()\\[\\\\])+ # any character (until end)\n )+\n )\n)?+\n# may end with a space only if it is an extended literal or contains only a single escaped space\n(?(3)|(?(5)(?<!\\s)))\n(/\\2) # (12)\n| \\#+/.+(\\n)",
30853085
"captures": {
30863086
"0": {
30873087
"patterns": [
@@ -3093,10 +3093,10 @@
30933093
"1": {
30943094
"name": "punctuation.definition.string.begin.regexp.swift"
30953095
},
3096-
"12": {
3096+
"8": {
30973097
"name": "punctuation.definition.string.end.regexp.swift"
30983098
},
3099-
"13": {
3099+
"9": {
31003100
"name": "invalid.illegal.returns-not-allowed.regexp"
31013101
}
31023102
}
@@ -3155,31 +3155,61 @@
31553155
}
31563156
},
31573157
{
3158-
"comment": "'\\k<' NamedOrNumberRef '>'\n \"\\k'\" NamedOrNumberRef \"'\"\n '\\g<' NamedOrNumberRef '>'\n \"\\g'\" NamedOrNumberRef \"'\"",
3159-
"match": "(?x)(\\\\[gk](<)|\\\\[gk]') (?: ((?!\\d)\\w+) (?:([+-])(\\d+))? | ([+-]?\\d+) (?:([+-])(\\d+))? ) ((?(2)>|'))",
3158+
"comment": "'\\k<' NamedOrNumberRef '>'\n '\\g<' NamedOrNumberRef '>'",
3159+
"match": "(?x)(\\\\[gk]<) (?: ((?!\\d)\\w+) (?:([+-])(\\d+))? | ([+-]?\\d+) (?:([+-])(\\d+))? ) (>)",
31603160
"captures": {
31613161
"1": {
31623162
"name": "constant.character.escape.backslash.regexp"
31633163
},
3164-
"3": {
3164+
"2": {
31653165
"name": "variable.other.group-name.regexp"
31663166
},
3167-
"4": {
3167+
"3": {
31683168
"name": "keyword.operator.recursion-level.regexp"
31693169
},
3170+
"4": {
3171+
"name": "constant.numeric.integer.decimal.regexp"
3172+
},
31703173
"5": {
31713174
"name": "constant.numeric.integer.decimal.regexp"
31723175
},
31733176
"6": {
3174-
"name": "constant.numeric.integer.decimal.regexp"
3177+
"name": "keyword.operator.recursion-level.regexp"
31753178
},
31763179
"7": {
3177-
"name": "keyword.operator.recursion-level.regexp"
3180+
"name": "constant.numeric.integer.decimal.regexp"
31783181
},
31793182
"8": {
3183+
"name": "constant.character.escape.backslash.regexp"
3184+
}
3185+
}
3186+
},
3187+
{
3188+
"comment": "\"\\k'\" NamedOrNumberRef \"'\"\n \"\\g'\" NamedOrNumberRef \"'\"",
3189+
"match": "(?x)(\\\\[gk]') (?: ((?!\\d)\\w+) (?:([+-])(\\d+))? | ([+-]?\\d+) (?:([+-])(\\d+))? ) (')",
3190+
"captures": {
3191+
"1": {
3192+
"name": "constant.character.escape.backslash.regexp"
3193+
},
3194+
"2": {
3195+
"name": "variable.other.group-name.regexp"
3196+
},
3197+
"3": {
3198+
"name": "keyword.operator.recursion-level.regexp"
3199+
},
3200+
"4": {
31803201
"name": "constant.numeric.integer.decimal.regexp"
31813202
},
3182-
"9": {
3203+
"5": {
3204+
"name": "constant.numeric.integer.decimal.regexp"
3205+
},
3206+
"6": {
3207+
"name": "keyword.operator.recursion-level.regexp"
3208+
},
3209+
"7": {
3210+
"name": "constant.numeric.integer.decimal.regexp"
3211+
},
3212+
"8": {
31833213
"name": "constant.character.escape.backslash.regexp"
31843214
}
31853215
}
@@ -3291,7 +3321,7 @@
32913321
},
32923322
"literals-regular-expression-literal-callout": {
32933323
"name": "meta.callout.regexp",
3294-
"match": "(?x)\n# PCRECallout\n(\\()(?<keyw>\\?C)\n (?:\n (?<num>\\d+)\n | `(?<name>(?:[^`]|``)*)`\n | '(?<name>(?:[^']|'')*)'\n | \"(?<name>(?:[^\"]|\"\")*)\"\n | \\^(?<name>(?:[^\\^]|\\^\\^)*)\\^\n | %(?<name>(?:[^%]|%%)*)%\n | \\#(?<name>(?:[^#]|\\#\\#)*)\\#\n | \\$(?<name>(?:[^$]|\\$\\$)*)\\$\n | \\{(?<name>(?:[^}]|\\}\\})*)\\}\n )?\n(\\))\n# NamedCallout\n| (\\()(?<keyw>\\*)\n (?<name>(?!\\d)\\w+)\n (?:\\[(?<tag>(?!\\d)\\w+)\\])?\n (?:\\{ [^,}]+ (?:,[^,}]+)* \\})?\n (\\))\n# InterpolatedCallout\n| (\\()(?<keyw>\\?)\n # we only support a fixed maximum number of braces because otherwise we can't balance the number of open and close braces\n (\\{(?<g1>\\{)?+(?<g2>\\{)?+(?<g3>\\{)?+(?<g4>\\{)?+(?<g5>\\{)?+) .+? \\}(?(<g1>)\\})(?(<g2>)\\})(?(<g3>)\\})(?(<g4>)\\})(?(<g5>)\\})\n (?:\\[(?<tag>(?!\\d)\\w+)\\])?\n (?<keyw>[X<>]?)\n (\\))",
3324+
"match": "(?x)\n# PCRECallout\n(\\()(?<keyw>\\?C)\n (?:\n (?<num>\\d+)\n | `(?<name>(?:[^`]|``)*)`\n | '(?<name>(?:[^']|'')*)'\n | \"(?<name>(?:[^\"]|\"\")*)\"\n | \\^(?<name>(?:[^\\^]|\\^\\^)*)\\^\n | %(?<name>(?:[^%]|%%)*)%\n | \\#(?<name>(?:[^#]|\\#\\#)*)\\#\n | \\$(?<name>(?:[^$]|\\$\\$)*)\\$\n | \\{(?<name>(?:[^}]|\\}\\})*)\\}\n )?\n(\\))\n# NamedCallout\n| (\\()(?<keyw>\\*)\n (?<name>(?!\\d)\\w+)\n (?:\\[(?<tag>(?!\\d)\\w+)\\])?\n (?:\\{ [^,}]+ (?:,[^,}]+)* \\})?\n (\\))\n# InterpolatedCallout\n| (\\()(?<keyw>\\?)\n (?>(\\{(?:\\g<-1>|(?!{).*?)\\}))\n (?:\\[(?<tag>(?!\\d)\\w+)\\])?\n (?<keyw>[X<>]?)\n (\\))",
32953325
"captures": {
32963326
"1": {
32973327
"name": "punctuation.definition.group.regexp"
@@ -3350,13 +3380,13 @@
33503380
"19": {
33513381
"name": "keyword.control.callout.regexp"
33523382
},
3353-
"26": {
3383+
"21": {
33543384
"name": "variable.language.tag-name.regexp"
33553385
},
3356-
"27": {
3386+
"22": {
33573387
"name": "keyword.control.callout.regexp"
33583388
},
3359-
"28": {
3389+
"23": {
33603390
"name": "punctuation.definition.group.regexp"
33613391
}
33623392
}

org.eclipse.tm4e.language_pack/syntaxes/typescript/typescript.language-configuration.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@
249249
// Add // when pressing enter from inside line comment
250250
{
251251
"beforeText": {
252-
"pattern": "\/\/.*"
252+
"pattern": "(?<!\\w:)\/\/.*"
253253
},
254254
"afterText": {
255255
"pattern": "^(?!\\s*$).+"

org.eclipse.tm4e.language_pack/syntaxes/typescript/typescriptreact.language-configuration.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@
249249
// Add // when pressing enter from inside line comment
250250
{
251251
"beforeText": {
252-
"pattern": "\/\/.*"
252+
"pattern": "(?<!\\w:)\/\/.*"
253253
},
254254
"afterText": {
255255
"pattern": "^(?!\\s*$).+"

org.eclipse.tm4e.language_pack/updater/updater-config.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ sources:
9494
github:
9595
repo: microsoft/vscode
9696
path: extensions
97-
ref: "1.97.2" # https://gitlab.eclipse.org/eclipsefdn/emo-team/iplab/-/issues/19521
97+
ref: "1.98.2" # https://gitlab.eclipse.org/eclipsefdn/emo-team/iplab/-/issues/20242
9898
license-download: false
9999
include-all-by-default: true
100100
extensions:

0 commit comments

Comments
 (0)