summaryrefslogtreecommitdiffstats
path: root/tests/mir-opt/simplify_locals.d2.SimplifyLocals-before-const-prop.diff
blob: 374c5895ebff4cfb30aaf38312ce24f9c78ab10b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
- // MIR for `d2` before SimplifyLocals-before-const-prop
+ // MIR for `d2` after SimplifyLocals-before-const-prop
  
  fn d2() -> () {
      let mut _0: ();
-     let mut _1: E;
-     let mut _2: (i32, E);
-     let mut _3: E;
  
      bb0: {
-         StorageLive(_1);
-         _1 = E::B;
-         StorageLive(_2);
-         StorageLive(_3);
-         _3 = E::A;
-         _2 = (const 10_i32, move _3);
-         StorageDead(_3);
-         (_2.1: E) = move _1;
-         StorageDead(_1);
-         StorageDead(_2);
          _0 = const ();
          return;
      }
  }