Skip to content

Commit

Permalink
🤖: update grammars
Browse files Browse the repository at this point in the history
  • Loading branch information
octref committed Dec 31, 2023
1 parent 249372e commit c4aa985
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions packages/shiki/languages/csharp.tmLanguage.json
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,9 @@
{
"include": "#comment"
},
{
"include": "#storage-modifier"
},
{
"include": "#property-declaration"
},
Expand All @@ -172,6 +175,9 @@
{
"include": "#method-declaration"
},
{
"include": "#operator-declaration"
},
{
"include": "#attribute-section"
},
Expand Down Expand Up @@ -2703,22 +2709,25 @@
"include": "#intrusive"
},
{
"match": "(?x)\n(?:\n (\\bvar\\b)|\n (?<type_name>\n (?:\n (?:\n (?:(?<identifier>@?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (?<name_and_type_args> # identifier + type arguments (if any)\n \\g<identifier>\\s*\n (?<type_args>\\s*<(?:[^<>]|\\g<type_args>)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g<name_and_type_args>)* | # Are there any more names being dotted into?\n (?<tuple>\\s*\\((?:[^\\(\\)]|\\g<tuple>)+\\))\n )\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s* # array suffix?\n \\[\n (?:\\s*,\\s*)* # commata for multi-dimensional arrays\n \\]\n \\s*\n (?:\\?)? # arrays can be nullable reference types\n \\s*\n )*\n )\n )\n)\\s+\n(\\g<identifier>)\\s+\n\\b(in)\\b",
"match": "(?x)\n(?:\n (?:(\\bref)\\s+)?(\\bvar\\b)| # ref local\n (?<type_name>\n (?:\n (?:ref\\s+)? # ref local\n (?:\n (?:(?<identifier>@?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (?<name_and_type_args> # identifier + type arguments (if any)\n \\g<identifier>\\s*\n (?<type_args>\\s*<(?:[^<>]|\\g<type_args>)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g<name_and_type_args>)* | # Are there any more names being dotted into?\n (?<tuple>\\s*\\((?:[^\\(\\)]|\\g<tuple>)+\\))\n )\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s* # array suffix?\n \\[\n (?:\\s*,\\s*)* # commata for multi-dimensional arrays\n \\]\n \\s*\n (?:\\?)? # arrays can be nullable reference types\n \\s*\n )*\n )\n )\n)\\s+\n(\\g<identifier>)\\s+\n\\b(in)\\b",
"captures": {
"1": {
"name": "storage.type.var.cs"
"name": "storage.modifier.ref.cs"
},
"2": {
"name": "storage.type.var.cs"
},
"3": {
"patterns": [
{
"include": "#type"
}
]
},
"7": {
"8": {
"name": "entity.name.variable.local.cs"
},
"8": {
"9": {
"name": "keyword.control.loop.in.cs"
}
}
Expand Down

0 comments on commit c4aa985

Please sign in to comment.