@@ -90,10 +90,7 @@ impl LoweringContext<'_> {
9090 ) ,
9191 ExprKind :: Async ( capture_clause, closure_node_id, ref block) => {
9292 self . make_async_expr ( capture_clause, closure_node_id, None , block. span , |this| {
93- this. with_new_scopes ( |this| {
94- let block = this. lower_block ( block, false ) ;
95- this. expr_block ( block, ThinVec :: new ( ) )
96- } )
93+ this. with_new_scopes ( |this| this. lower_block_expr ( block) )
9794 } )
9895 }
9996 ExprKind :: Await ( ref expr) => self . lower_expr_await ( e. span , expr) ,
@@ -284,8 +281,7 @@ impl LoweringContext<'_> {
284281 let else_arm = self . arm ( hir_vec ! [ else_pat] , P ( else_expr) ) ;
285282
286283 // Handle then + scrutinee:
287- let then_blk = self . lower_block ( then, false ) ;
288- let then_expr = self . expr_block ( then_blk, ThinVec :: new ( ) ) ;
284+ let then_expr = self . lower_block_expr ( then) ;
289285 let ( then_pat, scrutinee, desugar) = match cond. node {
290286 // `<pat> => <then>`:
291287 ExprKind :: Let ( ref pat, ref scrutinee) => {
@@ -335,8 +331,7 @@ impl LoweringContext<'_> {
335331 } ;
336332
337333 // Handle then + scrutinee:
338- let then_blk = self . lower_block ( body, false ) ;
339- let then_expr = self . expr_block ( then_blk, ThinVec :: new ( ) ) ;
334+ let then_expr = self . lower_block_expr ( body) ;
340335 let ( then_pat, scrutinee, desugar, source) = match cond. node {
341336 ExprKind :: Let ( ref pat, ref scrutinee) => {
342337 // to:
0 commit comments