fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
4.0 KiB158 linesraw
1- // MIR for `debuginfo` before ReferencePropagation
2+ // MIR for `debuginfo` after ReferencePropagation
3  
4  fn debuginfo() -> () {
5      let mut _0: ();
6      let _1: &mut u8;
7      let mut _2: u8;
8      let _4: debuginfo::T;
9      let _6: ();
10      let mut _7: std::option::Option<i32>;
11      let mut _8: isize;
12      let _10: ();
13      let mut _11: &[i32];
14      let _12: &[i32];
15      let mut _13: &[i32; 10];
16      let _14: [i32; 10];
17      let mut _15: std::ops::RangeFull;
18      let mut _16: usize;
19      let mut _17: usize;
20      let mut _18: bool;
21      let _23: &&mut u8;
22      let _24: &mut u8;
23      let mut _25: debuginfo::T;
24      scope 1 {
25          debug ref_mut_u8 => _1;
26          let _3: &u8;
27          let mut _28: &debuginfo::T;
28          scope 2 {
29              debug field => _3;
30              let _5: &u8;
31              scope 3 {
32-                 debug reborrow => _5;
33+                 debug reborrow => _1;
34                  let _9: &i32;
35                  let _22: &&&mut u8;
36                  let mut _27: &std::option::Option<i32>;
37                  scope 4 {
38                      debug variant_field => _9;
39                  }
40                  scope 5 {
41                      debug constant_index => _19;
42                      debug subslice => _20;
43                      debug constant_index_from_end => _21;
44                      let _19: &i32;
45                      let _20: &[i32];
46                      let _21: &i32;
47                      let mut _26: &[i32; 10];
48                  }
49                  scope 6 {
50                      debug multiple_borrow => _22;
51                  }
52              }
53          }
54      }
55  
56      bb0: {
57          StorageLive(_1);
58          StorageLive(_2);
59          _2 = const 5_u8;
60          _1 = &mut _2;
61          StorageLive(_3);
62          _28 = const _;
63          _3 = &((*_28).0: u8);
64-         StorageLive(_5);
65-         _5 = &(*_1);
66-         StorageLive(_6);
67          StorageLive(_7);
68          _7 = Option::<i32>::Some(const 0_i32);
69          _8 = discriminant(_7);
70          switchInt(move _8) -> [0: bb3, 1: bb1, otherwise: bb2];
71      }
72  
73      bb1: {
74          StorageLive(_9);
75          _27 = const _;
76          _9 = &(((*_27) as Some).0: i32);
77-         _6 = const ();
78          StorageDead(_9);
79          goto -> bb4;
80      }
81  
82      bb2: {
83          unreachable;
84      }
85  
86      bb3: {
87-         _6 = const ();
88          goto -> bb4;
89      }
90  
91      bb4: {
92          StorageDead(_7);
93-         StorageDead(_6);
94-         StorageLive(_10);
95          StorageLive(_11);
96          StorageLive(_12);
97          StorageLive(_13);
98          _26 = const _;
99          _13 = &(*_26);
100          StorageLive(_15);
101          _15 = RangeFull;
102          _12 = <[i32; 10] as Index<RangeFull>>::index(move _13, move _15) -> [return: bb5, unwind continue];
103      }
104  
105      bb5: {
106          StorageDead(_15);
107          StorageDead(_13);
108          _11 = &(*_12);
109          _16 = Len((*_11));
110          _17 = const 3_usize;
111          _18 = Ge(move _16, move _17);
112          switchInt(move _18) -> [0: bb7, otherwise: bb6];
113      }
114  
115      bb6: {
116          StorageLive(_19);
117          _19 = &(*_11)[1 of 3];
118          StorageLive(_20);
119          _20 = &(*_11)[2:-1];
120          StorageLive(_21);
121          _21 = &(*_11)[-1 of 3];
122-         _10 = const ();
123          StorageDead(_21);
124          StorageDead(_20);
125          StorageDead(_19);
126          goto -> bb8;
127      }
128  
129      bb7: {
130-         _10 = const ();
131          goto -> bb8;
132      }
133  
134      bb8: {
135          StorageDead(_12);
136          StorageDead(_11);
137-         StorageDead(_10);
138          StorageLive(_22);
139          StorageLive(_23);
140          StorageLive(_24);
141          StorageLive(_25);
142          _25 = T(const 6_u8);
143          _24 = &mut (_25.0: u8);
144          _23 = &_24;
145          _22 = &_23;
146          _0 = const ();
147          StorageDead(_25);
148          StorageDead(_24);
149          StorageDead(_23);
150          StorageDead(_22);
151-         StorageDead(_5);
152          StorageDead(_3);
153          StorageDead(_2);
154          StorageDead(_1);
155          return;
156      }
157  }
158