]> git.lizzy.rs Git - rust.git/blob - tests/mir-opt/remove_storage_markers.main.RemoveStorageMarkers.diff
a8dd91efc379f86fef4c776c80d2a693f00d806a
[rust.git] / tests / mir-opt / remove_storage_markers.main.RemoveStorageMarkers.diff
1 - // MIR for `main` before RemoveStorageMarkers
2 + // MIR for `main` after RemoveStorageMarkers
3   
4   fn main() -> () {
5       let mut _0: ();                      // return place in scope 0 at $DIR/remove_storage_markers.rs:+0:11: +0:11
6       let mut _1: i32;                     // in scope 0 at $DIR/remove_storage_markers.rs:+1:9: +1:16
7       let mut _2: std::ops::Range<i32>;    // in scope 0 at $DIR/remove_storage_markers.rs:+2:14: +2:19
8       let mut _3: std::ops::Range<i32>;    // in scope 0 at $DIR/remove_storage_markers.rs:+2:14: +2:19
9       let mut _5: ();                      // in scope 0 at $DIR/remove_storage_markers.rs:+0:1: +5:2
10       let _6: ();                          // in scope 0 at $DIR/remove_storage_markers.rs:+2:14: +2:19
11       let mut _7: std::option::Option<i32>; // in scope 0 at $DIR/remove_storage_markers.rs:+2:14: +2:19
12       let mut _8: &mut std::ops::Range<i32>; // in scope 0 at $DIR/remove_storage_markers.rs:+2:14: +2:19
13       let mut _9: &mut std::ops::Range<i32>; // in scope 0 at $DIR/remove_storage_markers.rs:+2:14: +2:19
14       let mut _10: isize;                  // in scope 0 at $DIR/remove_storage_markers.rs:+2:5: +4:6
15       let mut _11: !;                      // in scope 0 at $DIR/remove_storage_markers.rs:+2:5: +4:6
16       let mut _13: i32;                    // in scope 0 at $DIR/remove_storage_markers.rs:+3:16: +3:17
17       scope 1 {
18           debug sum => _1;                 // in scope 1 at $DIR/remove_storage_markers.rs:+1:9: +1:16
19           let mut _4: std::ops::Range<i32>; // in scope 1 at $DIR/remove_storage_markers.rs:+2:14: +2:19
20           scope 2 {
21               debug iter => _4;            // in scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
22               let _12: i32;                // in scope 2 at $DIR/remove_storage_markers.rs:+2:9: +2:10
23               scope 3 {
24                   debug i => _12;          // in scope 3 at $DIR/remove_storage_markers.rs:+2:9: +2:10
25               }
26           }
27       }
28   
29       bb0: {
30 -         StorageLive(_1);                 // scope 0 at $DIR/remove_storage_markers.rs:+1:9: +1:16
31           _1 = const 0_i32;                // scope 0 at $DIR/remove_storage_markers.rs:+1:19: +1:20
32 -         StorageLive(_2);                 // scope 1 at $DIR/remove_storage_markers.rs:+2:14: +2:19
33 -         StorageLive(_3);                 // scope 1 at $DIR/remove_storage_markers.rs:+2:14: +2:19
34           _3 = std::ops::Range::<i32> { start: const 0_i32, end: const 10_i32 }; // scope 1 at $DIR/remove_storage_markers.rs:+2:14: +2:19
35           _2 = <std::ops::Range<i32> as IntoIterator>::into_iter(move _3) -> bb1; // scope 1 at $DIR/remove_storage_markers.rs:+2:14: +2:19
36                                            // mir::Constant
37                                            // + span: $DIR/remove_storage_markers.rs:10:14: 10:19
38                                            // + literal: Const { ty: fn(std::ops::Range<i32>) -> <std::ops::Range<i32> as IntoIterator>::IntoIter {<std::ops::Range<i32> as IntoIterator>::into_iter}, val: Value(<ZST>) }
39       }
40   
41       bb1: {
42 -         StorageDead(_3);                 // scope 1 at $DIR/remove_storage_markers.rs:+2:18: +2:19
43 -         StorageLive(_4);                 // scope 1 at $DIR/remove_storage_markers.rs:+2:14: +2:19
44           _4 = move _2;                    // scope 1 at $DIR/remove_storage_markers.rs:+2:14: +2:19
45           goto -> bb2;                     // scope 2 at $DIR/remove_storage_markers.rs:+2:5: +4:6
46       }
47   
48       bb2: {
49 -         StorageLive(_6);                 // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
50 -         StorageLive(_7);                 // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
51 -         StorageLive(_8);                 // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
52 -         StorageLive(_9);                 // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
53           _9 = &mut _4;                    // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
54           _8 = &mut (*_9);                 // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
55           _7 = <std::ops::Range<i32> as Iterator>::next(move _8) -> bb3; // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
56                                            // mir::Constant
57                                            // + span: $DIR/remove_storage_markers.rs:10:14: 10:19
58                                            // + literal: Const { ty: for<'a> fn(&'a mut std::ops::Range<i32>) -> Option<<std::ops::Range<i32> as Iterator>::Item> {<std::ops::Range<i32> as Iterator>::next}, val: Value(<ZST>) }
59       }
60   
61       bb3: {
62 -         StorageDead(_8);                 // scope 2 at $DIR/remove_storage_markers.rs:+2:18: +2:19
63           _10 = discriminant(_7);          // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
64           switchInt(move _10) -> [0: bb6, 1: bb4, otherwise: bb5]; // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
65       }
66   
67       bb4: {
68 -         StorageLive(_12);                // scope 2 at $DIR/remove_storage_markers.rs:+2:9: +2:10
69           _12 = ((_7 as Some).0: i32);     // scope 2 at $DIR/remove_storage_markers.rs:+2:9: +2:10
70 -         StorageLive(_13);                // scope 3 at $DIR/remove_storage_markers.rs:+3:16: +3:17
71           _13 = _12;                       // scope 3 at $DIR/remove_storage_markers.rs:+3:16: +3:17
72           _1 = Add(_1, move _13);          // scope 3 at $DIR/remove_storage_markers.rs:+3:9: +3:17
73 -         StorageDead(_13);                // scope 3 at $DIR/remove_storage_markers.rs:+3:16: +3:17
74           _6 = const ();                   // scope 3 at $DIR/remove_storage_markers.rs:+2:20: +4:6
75 -         StorageDead(_12);                // scope 2 at $DIR/remove_storage_markers.rs:+4:5: +4:6
76 -         StorageDead(_9);                 // scope 2 at $DIR/remove_storage_markers.rs:+4:5: +4:6
77 -         StorageDead(_7);                 // scope 2 at $DIR/remove_storage_markers.rs:+4:5: +4:6
78 -         StorageDead(_6);                 // scope 2 at $DIR/remove_storage_markers.rs:+4:5: +4:6
79           _5 = const ();                   // scope 2 at $DIR/remove_storage_markers.rs:+2:5: +4:6
80           goto -> bb2;                     // scope 2 at $DIR/remove_storage_markers.rs:+2:5: +4:6
81       }
82   
83       bb5: {
84           unreachable;                     // scope 2 at $DIR/remove_storage_markers.rs:+2:14: +2:19
85       }
86   
87       bb6: {
88           _0 = const ();                   // scope 2 at $DIR/remove_storage_markers.rs:+2:5: +4:6
89 -         StorageDead(_9);                 // scope 2 at $DIR/remove_storage_markers.rs:+4:5: +4:6
90 -         StorageDead(_7);                 // scope 2 at $DIR/remove_storage_markers.rs:+4:5: +4:6
91 -         StorageDead(_6);                 // scope 2 at $DIR/remove_storage_markers.rs:+4:5: +4:6
92 -         StorageDead(_4);                 // scope 1 at $DIR/remove_storage_markers.rs:+4:5: +4:6
93 -         StorageDead(_2);                 // scope 1 at $DIR/remove_storage_markers.rs:+4:5: +4:6
94 -         StorageDead(_1);                 // scope 0 at $DIR/remove_storage_markers.rs:+5:1: +5:2
95           return;                          // scope 0 at $DIR/remove_storage_markers.rs:+5:2: +5:2
96       }
97   }
98