diff --git a/compiler/rustc_ast_pretty/src/pprust/state.rs b/compiler/rustc_ast_pretty/src/pprust/state.rs index b05215d7a34..bc6da9371aa 100644 --- a/compiler/rustc_ast_pretty/src/pprust/state.rs +++ b/compiler/rustc_ast_pretty/src/pprust/state.rs @@ -1161,16 +1161,8 @@ fn print_let(&mut self, pat: &ast::Pat, expr: &ast::Expr) { self.word_space("="); self.print_expr_cond_paren( expr, - match expr.kind { - ast::ExprKind::Break(..) - | ast::ExprKind::Closure(..) - | ast::ExprKind::Ret(..) - | ast::ExprKind::Yeet(..) => true, - _ => { - parser::contains_exterior_struct_lit(expr) - || parser::needs_par_as_let_scrutinee(expr.precedence().order()) - } - }, + parser::contains_exterior_struct_lit(expr) + || parser::needs_par_as_let_scrutinee(expr.precedence().order()), ); }