lift spaces in backpassing (fixes #7364)

This commit is contained in:
Joshua Warner 2024-12-13 19:07:52 -08:00
parent db95ff54cf
commit abde9e86b1
No known key found for this signature in database
GPG key ID: 89AD497003F93FDD
5 changed files with 65 additions and 2 deletions

View file

@ -1911,7 +1911,6 @@ fn fmt_backpassing<'a>(
loc_patterns: &'a [Loc<Pattern<'a>>],
loc_body: &'a Loc<Expr<'a>>,
loc_ret: &'a Loc<Expr<'a>>,
outer_indent: u16,
) {
use self::Expr::*;
@ -1936,7 +1935,7 @@ fn fmt_backpassing<'a>(
Parens::NotNeeded
};
let pat = loc_pattern.value.extract_spaces();
let pat = pattern_lift_spaces(buf.text.bump(), &loc_pattern.value);
if !first {
buf.indent(arg_indent);