]> git.lizzy.rs Git - rust.git/commitdiff
liveness: Remove unnecessary local variable exit_ln
authorTomasz Miąsko <tomasz.miasko@gmail.com>
Sat, 26 Sep 2020 00:00:00 +0000 (00:00 +0000)
committerTomasz Miąsko <tomasz.miasko@gmail.com>
Sat, 26 Sep 2020 14:44:28 +0000 (16:44 +0200)
compiler/rustc_passes/src/liveness.rs

index cb452d3d04153cbdea4c8a0b20855330666bd9ab..402f889ac8c49fc41a55d25bd4124211b2fd5558 100644 (file)
@@ -1093,9 +1093,8 @@ fn propagate_through_expr(&mut self, expr: &Expr<'_>, succ: LiveNode) -> LiveNod
             }
 
             hir::ExprKind::Ret(ref o_e) => {
-                // ignore succ and subst exit_ln:
-                let exit_ln = self.exit_ln;
-                self.propagate_through_opt_expr(o_e.as_ref().map(|e| &**e), exit_ln)
+                // Ignore succ and subst exit_ln.
+                self.propagate_through_opt_expr(o_e.as_ref().map(|e| &**e), self.exit_ln)
             }
 
             hir::ExprKind::Break(label, ref opt_expr) => {