Skip to content

Commit ae033f4

Browse files
committed
feat: update language pack grammars
1 parent 6498ef1 commit ae033f4

17 files changed

Lines changed: 1067 additions & 531 deletions

org.eclipse.tm4e.language_pack/README.md

Lines changed: 61 additions & 61 deletions
Large diffs are not rendered by default.

org.eclipse.tm4e.language_pack/about.html

Lines changed: 66 additions & 66 deletions
Large diffs are not rendered by default.

org.eclipse.tm4e.language_pack/plugin.xml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -920,6 +920,7 @@
920920
<!-- ======================================== -->
921921
<extension point="org.eclipse.tm4e.registry.grammars">
922922
<grammar scopeName="markdown.math.block" path="syntaxes/markdown-math/markdown.math.block.tmLanguage.json" />
923+
<grammar scopeName="markdown.math.codeblock" path="syntaxes/markdown-math/markdown.math.codeblock.tmLanguage.json" />
923924
<grammar scopeName="markdown.math.inline" path="syntaxes/markdown-math/markdown.math.inline.tmLanguage.json" />
924925
</extension>
925926

@@ -1266,7 +1267,7 @@
12661267
<!-- ======================================== -->
12671268
<extension point="org.eclipse.core.contenttype.contentTypes">
12681269
<content-type id="org.eclipse.tm4e.language_pack.shellscript" name="Shell Script" base-type="org.eclipse.tm4e.language_pack.basetype" priority="low"
1269-
file-extensions="Xsession,bash,bash_aliases,bash_login,bash_logout,bash_profile,bashrc,csh,cshrc,ebuild,fish,ksh,profile,sh,tcshrc,xprofile,xsession,xsessionrc,yash_profile,yashrc,zlogin,zlogout,zprofile,zsh,zsh-theme,zshenv,zshrc" file-names=".envrc,.hushlogin,APKBUILD,PKGBUILD,bashrc_Apple_Terminal,zlogin,zlogout,zprofile,zshenv,zshrc,zshrc_Apple_Terminal" file-patterns=".env.*" />
1270+
file-extensions="Xsession,bash,bash_aliases,bash_login,bash_logout,bash_profile,bashrc,csh,cshrc,ebuild,eclass,fish,ksh,profile,sh,tcshrc,xprofile,xsession,xsessionrc,yash_profile,yashrc,zlogin,zlogout,zprofile,zsh,zsh-theme,zshenv,zshrc" file-names=".envrc,.hushlogin,APKBUILD,PKGBUILD,bashrc_Apple_Terminal,zlogin,zlogout,zprofile,zshenv,zshrc,zshrc_Apple_Terminal" file-patterns=".env.*" />
12701271
</extension>
12711272
<extension point="org.eclipse.tm4e.registry.grammars">
12721273
<grammar scopeName="source.shell" path="syntaxes/shellscript/shellscript.tmLanguage.json" />
@@ -1282,10 +1283,10 @@
12821283
</extension>
12831284

12841285
<!-- ======================================== -->
1285-
<!-- sql/sql: SQL -->
1286+
<!-- sql/sql: MS SQL -->
12861287
<!-- ======================================== -->
12871288
<extension point="org.eclipse.core.contenttype.contentTypes">
1288-
<content-type id="org.eclipse.tm4e.language_pack.sql" name="SQL" base-type="org.eclipse.tm4e.language_pack.basetype" priority="low"
1289+
<content-type id="org.eclipse.tm4e.language_pack.sql" name="MS SQL" base-type="org.eclipse.tm4e.language_pack.basetype" priority="low"
12891290
file-extensions="dsql,sql" />
12901291
</extension>
12911292
<extension point="org.eclipse.tm4e.registry.grammars">
@@ -1298,7 +1299,7 @@
12981299
</extension>
12991300

13001301
<extension point="org.eclipse.tm4e.ui.snippets">
1301-
<snippet name="SQL Example" path="syntaxes/sql/sql.example.sql" scopeName="source.sql" />
1302+
<snippet name="MS SQL Example" path="syntaxes/sql/sql.example.sql" scopeName="source.sql" />
13021303
</extension>
13031304

13041305
<!-- ======================================== -->

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

Lines changed: 4 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/dotnet/csharp-tmLanguage/commit/7a7482ffc72a6677a87eb1ed76005593a4f7f131",
7+
"version": "https://github.com/dotnet/csharp-tmLanguage/commit/d63e2661d4e0c83b6c7810eb1d0eedc5da843b04",
88
"name": "C#",
99
"scopeName": "source.cs",
1010
"patterns": [
@@ -512,6 +512,9 @@
512512
{
513513
"include": "#type-name"
514514
},
515+
{
516+
"include": "#type-arguments"
517+
},
515518
{
516519
"include": "#attribute-arguments"
517520
}

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

Lines changed: 9 additions & 6 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/ionide/ionide-fsgrammar/commit/7d029a46f17637228b2ee85dd02e511c3e8039b3",
7+
"version": "https://github.com/ionide/ionide-fsgrammar/commit/7d1b695da917dc4c7a0f7fb4683f42da208f87a2",
88
"name": "fsharp",
99
"scopeName": "source.fsharp",
1010
"patterns": [
@@ -617,7 +617,7 @@
617617
},
618618
{
619619
"name": "constant.numeric.float.fsharp",
620-
"match": "\\b-?[0-9][0-9_]*((\\.([0-9][0-9_]*([eE][+-]??[0-9][0-9_]*)?)?)|([eE][+-]??[0-9][0-9_]*))"
620+
"match": "\\b-?[0-9][0-9_]*((\\.(?!\\.)([0-9][0-9_]*([eE][+-]??[0-9][0-9_]*)?)?)|([eE][+-]??[0-9][0-9_]*))"
621621
},
622622
{
623623
"name": "constant.numeric.integer.nativeint.fsharp",
@@ -635,7 +635,7 @@
635635
},
636636
"abstract_definition": {
637637
"name": "abstract.definition.fsharp",
638-
"begin": "\\b(abstract)\\s+(member)?(\\s+\\[\\<.*\\>\\])?\\s*([_[:alpha:]0-9,\\._`\\s]+)(<)?",
638+
"begin": "\\b(static)?\\s+(abstract)\\s+(member)?(\\s+\\[\\<.*\\>\\])?\\s*([_[:alpha:]0-9,\\._`\\s]+)(<)?",
639639
"end": "\\s*(with)\\b|=|$",
640640
"beginCaptures": {
641641
"1": {
@@ -645,6 +645,9 @@
645645
"name": "keyword.fsharp"
646646
},
647647
"3": {
648+
"name": "keyword.fsharp"
649+
},
650+
"4": {
648651
"name": "support.function.attribute.fsharp"
649652
},
650653
"5": {
@@ -838,7 +841,7 @@
838841
"name": "keyword.symbol.fsharp"
839842
}
840843
},
841-
"end": "(\\)\\s*(([?[:alpha:]0-9'`^._ ]+))+)",
844+
"end": "(\\)\\s*(([?[:alpha:]0-9'`^._ ]+))*)",
842845
"endCaptures": {
843846
"1": {
844847
"name": "keyword.symbol.fsharp"
@@ -933,7 +936,7 @@
933936
"patterns": [
934937
{
935938
"name": "binding.fsharp",
936-
"begin": "\\b(let mutable|static let mutable|static let|let inline|let|and|member val|static member inline|static member|default|member|override|let!)(\\s+rec|mutable)?(\\s+\\[\\<.*\\>\\])?\\s*(private|internal|public)?\\s+(\\[[^-=]*\\]|[_[:alpha:]]([_[:alpha:]0-9\\._]+)*|``[_[:alpha:]]([_[:alpha:]0-9\\._`\\s]+|(?<=,)\\s)*)?",
939+
"begin": "\\b(let mutable|static let mutable|static let|let inline|let|and|member val|member inline|static member inline|static member|default|member|override|let!)(\\s+rec|mutable)?(\\s+\\[\\<.*\\>\\])?\\s*(private|internal|public)?\\s+(\\[[^-=]*\\]|[_[:alpha:]]([_[:alpha:]0-9\\._]+)*|``[_[:alpha:]]([_[:alpha:]0-9\\._`\\s]+|(?<=,)\\s)*)?",
937940
"end": "\\s*((with\\b)|(=|\\n+=|(?<=\\=)))",
938941
"beginCaptures": {
939942
"1": {
@@ -1008,7 +1011,7 @@
10081011
},
10091012
{
10101013
"name": "binding.fsharp",
1011-
"begin": "\\b(static val mutable|val mutable|val)(\\s+rec|mutable)?(\\s+\\[\\<.*\\>\\])?\\s*(private|internal|public)?\\s+(\\[[^-=]*\\]|[_[:alpha:]]([_[:alpha:]0-9,\\._]+)*|``[_[:alpha:]]([_[:alpha:]0-9,\\._`\\s]+|(?<=,)\\s)*)?",
1014+
"begin": "\\b(static val mutable|val mutable|val inline|val)(\\s+rec|mutable)?(\\s+\\[\\<.*\\>\\])?\\s*(private|internal|public)?\\s+(\\[[^-=]*\\]|[_[:alpha:]]([_[:alpha:]0-9,\\._]+)*|``[_[:alpha:]]([_[:alpha:]0-9,\\._`\\s]+|(?<=,)\\s)*)?",
10121015
"end": "\\n$",
10131016
"beginCaptures": {
10141017
"1": {

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

Lines changed: 40 additions & 73 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/worlpaker/go-syntax/commit/092c45ec9a51fe40188408d1371f123eaa4796fa",
7+
"version": "https://github.com/worlpaker/go-syntax/commit/21f28840e04d4fa04682d19d6fe64de437f40b64",
88
"name": "Go",
99
"scopeName": "source.go",
1010
"patterns": [
@@ -321,7 +321,7 @@
321321
"name": "punctuation.definition.begin.bracket.square.go"
322322
}
323323
},
324-
"end": "(?:(\\])((?:(?:(?:[\\*\\[\\]]+)?(?:\\<\\-\\s*)?\\bchan\\b(?:\\s*\\<\\-)?\\s*)+)?(?!(?:[\\[\\]\\*]+)?\\b(?:func|struct|map)\\b)(?:[\\*\\[\\]]+)?(?:[\\w\\.]+))?)",
324+
"end": "(?:(\\])((?:(?:(?:[\\*\\[\\]]+)?(?:\\<\\-\\s*)?\\bchan\\b(?:\\s*\\<\\-)?\\s*)+)?(?!(?:[\\[\\]\\*]+)?\\b(?:func|struct|map)\\b)(?:[\\*\\[\\]]+)?(?:[\\w\\.]+)(?:\\[(?:(?:[\\w\\.\\*\\[\\]\\{\\}]+)(?:(?:\\,\\s*(?:[\\w\\.\\*\\[\\]\\{\\}]+))*))?\\])?)?)",
325325
"endCaptures": {
326326
"1": {
327327
"name": "punctuation.definition.end.bracket.square.go"
@@ -1862,7 +1862,7 @@
18621862
},
18631863
{
18641864
"comment": "property variables and types",
1865-
"match": "(?:((?:(?:\\w+\\,\\s*)+)?(?:\\w+\\s+))([\\s\\S]+))",
1865+
"match": "(?:((?:(?:\\w+\\,\\s*)+)?(?:\\w+\\s+))([^\\`]+))",
18661866
"captures": {
18671867
"1": {
18681868
"patterns": [
@@ -2007,6 +2007,29 @@
20072007
}
20082008
]
20092009
},
2010+
{
2011+
"comment": "one type only with multi line raw string",
2012+
"begin": "(?:((?:(?:\\s*(?:[\\*\\[\\]]+)?(?:\\<\\-\\s*)?\\bchan\\b(?:\\s*\\<\\-)?\\s*)+)?(?<!\\,\\s*)(?:[\\w\\.\\*]+)\\s*)(?=\\`))",
2013+
"beginCaptures": {
2014+
"1": {
2015+
"patterns": [
2016+
{
2017+
"include": "#type-declarations"
2018+
},
2019+
{
2020+
"match": "\\w+",
2021+
"name": "entity.name.type.go"
2022+
}
2023+
]
2024+
}
2025+
},
2026+
"end": "(?=\\`)",
2027+
"patterns": [
2028+
{
2029+
"include": "#raw_string_literals"
2030+
}
2031+
]
2032+
},
20102033
{
20112034
"include": "#parameter-variable-types"
20122035
}
@@ -2192,7 +2215,7 @@
21922215
]
21932216
}
21942217
},
2195-
"end": "(?:(?<=\\])((?:\\s+)(?:(?:(?:[\\*\\[\\]]+)?(?:\\<\\-\\s*)?\\bchan\\b(?:\\s*\\<\\-)?\\s*)+)?(?:(?!(?:[\\[\\]\\*]+)?(?:\\bstruct\\b|\\binterface\\b|\\bfunc\\b))[\\w\\.\\-\\*\\[\\]]+))?)",
2218+
"end": "(?:(?<=\\])((?:\\s+)(?:(?:(?:[\\*\\[\\]]+)?(?:\\<\\-\\s*)?\\bchan\\b(?:\\s*\\<\\-)?\\s*)+)?(?:(?!(?:[\\[\\]\\*]+)?(?:\\bstruct\\b|\\binterface\\b|\\bfunc\\b))[\\w\\.\\-\\*\\[\\]]+(?:\\,\\s+[\\w\\.\\[\\]\\*]+)*))?)",
21962219
"endCaptures": {
21972220
"1": {
21982221
"patterns": [
@@ -2271,6 +2294,9 @@
22712294
{
22722295
"include": "#struct_variables_types"
22732296
},
2297+
{
2298+
"include": "#interface_variables_types"
2299+
},
22742300
{
22752301
"include": "#type-declarations-without-brackets"
22762302
},
@@ -2439,7 +2465,7 @@
24392465
},
24402466
"switch_types": {
24412467
"comment": "switch type assertions, only highlights types after case keyword",
2442-
"begin": "(?<=\\bswitch\\b)(?:\\s*)(?:(\\w+\\s*\\:\\=)?\\s*([\\w\\.\\*\\(\\)\\[\\]]+))(\\.\\(\\btype\\b\\)\\s*)(\\{)",
2468+
"begin": "(?<=\\bswitch\\b)(?:\\s*)(?:(\\w+\\s*\\:\\=)?\\s*([\\w\\.\\*\\(\\)\\[\\]\\+/\\-\\%\\<\\>\\|\\&]+))(\\.\\(\\btype\\b\\)\\s*)(\\{)",
24432469
"beginCaptures": {
24442470
"1": {
24452471
"patterns": [
@@ -2770,7 +2796,7 @@
27702796
},
27712797
"slice_index_variables": {
27722798
"comment": "slice index and capacity variables, to not scope them as property variables",
2773-
"match": "(?<=\\w\\[)((?:(?:\\b[\\w\\.\\*\\+/\\-\\*\\%\\<\\>\\|\\&]+\\:)|(?:\\:\\b[\\w\\.\\*\\+/\\-\\*\\%\\<\\>\\|\\&]+))(?:\\b[\\w\\.\\*\\+/\\-\\*\\%\\<\\>\\|\\&]+)?(?:\\:\\b[\\w\\.\\*\\+/\\-\\*\\%\\<\\>\\|\\&]+)?)(?=\\])",
2799+
"match": "(?<=\\w\\[)((?:(?:\\b[\\w\\.\\*\\+/\\-\\%\\<\\>\\|\\&]+\\:)|(?:\\:\\b[\\w\\.\\*\\+/\\-\\%\\<\\>\\|\\&]+))(?:\\b[\\w\\.\\*\\+/\\-\\%\\<\\>\\|\\&]+)?(?:\\:\\b[\\w\\.\\*\\+/\\-\\%\\<\\>\\|\\&]+)?)(?=\\])",
27742800
"captures": {
27752801
"1": {
27762802
"patterns": [
@@ -2786,8 +2812,8 @@
27862812
}
27872813
},
27882814
"property_variables": {
2789-
"comment": "Property variables in struct | parameter field in struct initialization",
2790-
"match": "(?:(?:((?:\\b[\\w\\.]+)(?:\\:(?!\\=))))(?:(?:\\s*([\\w\\.\\*\\&\\[\\]]+)(\\.\\w+)(?![\\w\\.\\*\\&\\[\\]]*(?:\\{|\\()))((?:\\s*(?:\\<|\\>|\\<\\=|\\>\\=|\\=\\=|\\!\\=|\\|\\||\\&\\&|\\+|/|\\-|\\*|\\%|\\||\\&)\\s*(?:[\\w\\.\\*\\&\\[\\]]+)(?:\\.\\w+)(?![\\w\\.\\*\\&\\[\\]]*(?:\\{|\\()))*))?)",
2815+
"comment": "Property variables in struct",
2816+
"match": "((?:\\b[\\w\\.]+)(?:\\:(?!\\=)))",
27912817
"captures": {
27922818
"1": {
27932819
"patterns": [
@@ -2799,68 +2825,6 @@
27992825
"name": "variable.other.property.go"
28002826
}
28012827
]
2802-
},
2803-
"2": {
2804-
"patterns": [
2805-
{
2806-
"include": "#type-declarations"
2807-
},
2808-
{
2809-
"match": "\\w+",
2810-
"name": "variable.other.go"
2811-
},
2812-
{
2813-
"include": "$self"
2814-
}
2815-
]
2816-
},
2817-
"3": {
2818-
"patterns": [
2819-
{
2820-
"include": "#type-declarations"
2821-
},
2822-
{
2823-
"match": "\\w+",
2824-
"name": "variable.other.property.field.go"
2825-
},
2826-
{
2827-
"include": "$self"
2828-
}
2829-
]
2830-
},
2831-
"4": {
2832-
"patterns": [
2833-
{
2834-
"match": "([\\w\\.\\*\\&\\[\\]]+)(\\.\\w+)",
2835-
"captures": {
2836-
"1": {
2837-
"patterns": [
2838-
{
2839-
"include": "#type-declarations"
2840-
},
2841-
{
2842-
"match": "\\w+",
2843-
"name": "variable.other.go"
2844-
}
2845-
]
2846-
},
2847-
"2": {
2848-
"patterns": [
2849-
{
2850-
"include": "#type-declarations"
2851-
},
2852-
{
2853-
"match": "\\w+",
2854-
"name": "variable.other.property.field.go"
2855-
}
2856-
]
2857-
}
2858-
}
2859-
},
2860-
{
2861-
"include": "$self"
2862-
}
2863-
]
28642828
}
28652829
}
28662830
},
@@ -2931,13 +2895,16 @@
29312895
},
29322896
"2": {
29332897
"patterns": [
2934-
{
2935-
"include": "#type-declarations"
2936-
},
29372898
{
29382899
"match": "\\binvalid\\b\\s+\\btype\\b",
29392900
"name": "invalid.field.go"
29402901
},
2902+
{
2903+
"include": "#type-declarations-without-brackets"
2904+
},
2905+
{
2906+
"include": "#parameter-variable-types"
2907+
},
29412908
{
29422909
"match": "\\w+",
29432910
"name": "entity.name.type.go"

org.eclipse.tm4e.language_pack/syntaxes/julia/julia.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/JuliaEditorSupport/atom-language-julia/commit/663bf8d943fd8440f4ae7565f73327dd616bf191",
7+
"version": "https://github.com/JuliaEditorSupport/atom-language-julia/commit/c686684f18153687886e7d19c1bfc3a33076b1ab",
88
"name": "Julia",
99
"scopeName": "source.julia",
1010
"comment": "This grammar is used by Atom (Oniguruma), GitHub (PCRE), and VSCode (Oniguruma),\nso all regexps must be compatible with both engines.\n\nSpecs:\n- https://github.com/kkos/oniguruma/blob/master/doc/RE\n- https://www.pcre.org/current/doc/html/",
@@ -333,7 +333,7 @@
333333
"name": "keyword.control.using.julia"
334334
},
335335
{
336-
"match": "(?<=\\w\\s)\\b(as)\\b(?=\\s\\w)",
336+
"match": "(?<=\\S\\s+)\\b(as)\\b(?=\\s+\\S)",
337337
"name": "keyword.control.as.julia"
338338
},
339339
{

0 commit comments

Comments
 (0)