Allow incorrect indents for closing braces, to be fixed in the formatter

This commit is contained in:
Joshua Warner 2022-02-26 13:31:45 -08:00
parent 2682193b76
commit 0e3b9e5624

View file

@ -1214,7 +1214,11 @@ macro_rules! collection_trailing_sep_e {
$indent_problem
)
),
$crate::blankspace::space0_e($min_indent, $indent_problem)
$crate::blankspace::space0_e(
// we use min_indent=0 because we want to parse incorrectly indented closing braces
// and later fix these up in the formatter.
0 /* min_indent */,
$indent_problem)
).parse(arena, state)?;
let (_,_, state) =