@willbooster/tree-sitter-c-sharp 1.0.9 → 1.0.10
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/grammar.js +9 -3
- package/package.json +1 -1
- package/tree-sitter-c_sharp.wasm +0 -0
- package/tree-sitter.json +1 -1
package/grammar.js
CHANGED
|
@@ -83,6 +83,7 @@ module.exports = grammar({
|
|
|
83
83
|
[$.constant_pattern, $.lvalue_expression, $._name],
|
|
84
84
|
|
|
85
85
|
[$.type, $._name_invocation_pattern, $.recursive_pattern],
|
|
86
|
+
[$.type, $.recursive_pattern],
|
|
86
87
|
[$.attribute, $.type, $._name_invocation_pattern, $.recursive_pattern],
|
|
87
88
|
|
|
88
89
|
[$.parenthesized_pattern, $._parenthesized_pattern_with_designation],
|
|
@@ -1082,10 +1083,15 @@ module.exports = grammar({
|
|
|
1082
1083
|
prec.dynamic(1, seq($.positional_pattern_clause, $._simple_designation)),
|
|
1083
1084
|
// positional pattern without variable designation (no type prefix)
|
|
1084
1085
|
$.positional_pattern_clause,
|
|
1085
|
-
// other type followed by
|
|
1086
|
+
// other type followed by a property pattern clause
|
|
1087
|
+
seq(field('type', $.type), $.property_pattern_clause, optional($._simple_designation)),
|
|
1088
|
+
// A positional clause follows only a name (above), a predefined type, or an array type. Letting any type take
|
|
1089
|
+
// one reads `Name(A.B)` once more, through `type`; after a syntax error, the extra GLR versions then exceed
|
|
1090
|
+
// the runtime's limit, and which reading survives depends on the versions alive, not on dynamic precedence.
|
|
1086
1091
|
seq(
|
|
1087
|
-
field('type', $.
|
|
1088
|
-
|
|
1092
|
+
field('type', choice($.predefined_type, $.array_type)),
|
|
1093
|
+
$.positional_pattern_clause,
|
|
1094
|
+
optional($.property_pattern_clause),
|
|
1089
1095
|
optional($._simple_designation)
|
|
1090
1096
|
),
|
|
1091
1097
|
// no type, just pattern clauses (no variable designation to avoid conflict with above)
|
package/package.json
CHANGED
package/tree-sitter-c_sharp.wasm
CHANGED
|
Binary file
|