summaryrefslogtreecommitdiff
path: root/tests/mir-opt/reference_prop.multiple_storage.ReferencePropagation.diff
blob: 07bfdf0b2f12dd32c24cca1a963df24cfbd88c5d (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
26
27
- // MIR for `multiple_storage` before ReferencePropagation
+ // MIR for `multiple_storage` after ReferencePropagation
  
  fn multiple_storage() -> () {
      let mut _0: ();                      // return place in scope 0 at $DIR/reference_prop.rs:+0:23: +0:23
      let mut _1: i32;                     // in scope 0 at $SRC_DIR/core/src/intrinsics/mir.rs:LL:COL
      let mut _2: &i32;                    // in scope 0 at $SRC_DIR/core/src/intrinsics/mir.rs:LL:COL
      let mut _3: i32;                     // in scope 0 at $SRC_DIR/core/src/intrinsics/mir.rs:LL:COL
  
      bb0: {
          StorageLive(_1);                 // scope 0 at $DIR/reference_prop.rs:+6:13: +6:27
          _1 = const 5_i32;                // scope 0 at $DIR/reference_prop.rs:+7:13: +7:18
          _2 = &_1;                        // scope 0 at $SRC_DIR/core/src/intrinsics/mir.rs:LL:COL
          StorageDead(_1);                 // scope 0 at $DIR/reference_prop.rs:+9:13: +9:27
          StorageLive(_1);                 // scope 0 at $DIR/reference_prop.rs:+10:13: +10:27
          _3 = (*_2);                      // scope 0 at $SRC_DIR/core/src/intrinsics/mir.rs:LL:COL
          _0 = opaque::<i32>(_3) -> bb1;   // scope 0 at $DIR/reference_prop.rs:+14:13: +14:43
                                           // mir::Constant
                                           // + span: $DIR/reference_prop.rs:357:33: 357:39
                                           // + literal: Const { ty: fn(i32) {opaque::<i32>}, val: Value(<ZST>) }
      }
  
      bb1: {
          return;                          // scope 0 at $DIR/reference_prop.rs:+18:13: +18:21
      }
  }