|
83 | 83 | //!
|
84 | 84 | //! - `exit_ln`: a live node that is generated to represent every 'exit' from
|
85 | 85 | //! the function, whether it be by explicit return, panic, or other means.
|
86 |
| -//! |
87 |
| -//! - `fallthrough_ln`: a live node that represents a fallthrough |
88 | 86 |
|
89 | 87 | use self::LiveNodeKind::*;
|
90 | 88 | use self::VarKind::*;
|
@@ -638,7 +636,6 @@ impl RWUTable {
|
638 | 636 | #[derive(Copy, Clone)]
|
639 | 637 | struct Specials {
|
640 | 638 | exit_ln: LiveNode,
|
641 |
| - fallthrough_ln: LiveNode, |
642 | 639 | }
|
643 | 640 |
|
644 | 641 | const ACC_READ: u32 = 1;
|
@@ -668,7 +665,6 @@ impl<'a, 'tcx> Liveness<'a, 'tcx> {
|
668 | 665 | // an implicit return
|
669 | 666 | let specials = Specials {
|
670 | 667 | exit_ln: ir.add_live_node(ExitNode),
|
671 |
| - fallthrough_ln: ir.add_live_node(ExitNode), |
672 | 668 | };
|
673 | 669 |
|
674 | 670 | let tables = ir.tcx.typeck_tables_of(def_id);
|
@@ -897,12 +893,8 @@ impl<'a, 'tcx> Liveness<'a, 'tcx> {
|
897 | 893 | fn compute(&mut self, body: &hir::Expr<'_>) -> LiveNode {
|
898 | 894 | debug!("compute: using id for body, {:?}", body);
|
899 | 895 |
|
900 |
| - // the fallthrough exit is only for those cases where we do not |
901 |
| - // explicitly return: |
902 | 896 | let s = self.s;
|
903 |
| - self.init_from_succ(s.fallthrough_ln, s.exit_ln); |
904 |
| - |
905 |
| - let entry_ln = self.propagate_through_expr(body, s.fallthrough_ln); |
| 897 | + let entry_ln = self.propagate_through_expr(body, s.exit_ln); |
906 | 898 |
|
907 | 899 | // hack to skip the loop unless debug! is enabled:
|
908 | 900 | debug!(
|
|
0 commit comments