Fix crash with doubly-nested parens in patterns

This commit is contained in:
Joshua Warner 2024-12-24 14:08:52 -05:00
parent 941c6c4fe3
commit 8f0566a55f
No known key found for this signature in database
GPG key ID: 89AD497003F93FDD
7 changed files with 82 additions and 1 deletions

View file

@ -0,0 +1,32 @@
@0-13 SpaceAfter(
Closure(
[
@1-5 Apply(
@1-2 Tag(
"L",
),
[
@4-5 SpaceAfter(
SpaceAfter(
Identifier {
ident: "z",
},
[
Newline,
],
),
[
Newline,
],
),
],
),
],
@11-13 Num(
"42",
),
),
[
Newline,
],
)

View file

@ -353,6 +353,7 @@ mod test_snapshots {
pass/closure_in_apply_in_binop.expr,
pass/closure_in_binop_with_spaces.expr,
pass/closure_newline_empty_record_newline.expr,
pass/closure_parens_double_newlines.expr,
pass/closure_pat_reccord_comment.expr,
pass/closure_with_underscores.expr,
pass/comma_prefixed_indented_record.expr,