10237: fix: Do not wrap inlined local in parens when at block tail position r=Veykril a=Veykril

bors r+

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
This commit is contained in:
bors[bot] 2021-09-14 16:30:41 +00:00 committed by GitHub
commit 62288f57cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -107,6 +107,7 @@ pub(crate) fn inline_local_variable(acc: &mut Assists, ctx: &AssistContext) -> O
| ast::Expr::BreakExpr(_)
| ast::Expr::ReturnExpr(_)
| ast::Expr::MatchExpr(_)
| ast::Expr::BlockExpr(_)
);
Some((range, name_ref, !(initializer || parent)))
})