Skip to content

Commit 30046ca

Browse files
committed
fix lazy pattern
1 parent df909f3 commit 30046ca

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

grammar.js

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ module.exports = grammar({
6969
],
7070
[$._jsx_attribute_value, $.pipe_expression],
7171
[$.function_type_parameters, $.function_type],
72-
[$._reserved_identifier, $.module_unpack]
72+
[$._reserved_identifier, $.module_unpack],
73+
[$.lazy_pattern, $.or_pattern]
7374
],
7475

7576
conflicts: $ => [
@@ -925,13 +926,7 @@ module.exports = grammar({
925926

926927
lazy_pattern: $ => seq(
927928
'lazy',
928-
choice(
929-
$.value_identifier,
930-
$._literal_pattern,
931-
$._destructuring_pattern,
932-
$.polyvar_type_pattern,
933-
$.parenthesized_pattern,
934-
)
929+
$._pattern
935930
),
936931

937932
_jsx_element: $ => choice($.jsx_element, $.jsx_self_closing_element),

0 commit comments

Comments
 (0)