2022-05-11 16:27:06 -05:00
|
|
|
- // MIR for `main` before Derefer
|
|
|
|
+ // MIR for `main` after Derefer
|
|
|
|
|
|
|
|
fn main() -> () {
|
2022-07-27 13:47:42 -05:00
|
|
|
let mut _0: (); // return place in scope 0 at $DIR/derefer_inline_test.rs:+0:11: +0:11
|
2023-02-27 07:07:44 -06:00
|
|
|
let _1: std::boxed::Box<std::boxed::Box<u32>>; // in scope 0 at $DIR/derefer_inline_test.rs:+1:5: +1:18
|
|
|
|
let mut _2: std::boxed::Box<u32>; // in scope 0 at $DIR/derefer_inline_test.rs:+1:14: +1:17
|
2022-05-11 16:27:06 -05:00
|
|
|
|
|
|
|
bb0: {
|
2023-02-27 07:07:44 -06:00
|
|
|
StorageLive(_1); // scope 0 at $DIR/derefer_inline_test.rs:+1:5: +1:18
|
|
|
|
StorageLive(_2); // scope 0 at $DIR/derefer_inline_test.rs:+1:14: +1:17
|
|
|
|
_2 = f() -> bb1; // scope 0 at $DIR/derefer_inline_test.rs:+1:14: +1:17
|
2022-05-11 16:27:06 -05:00
|
|
|
// mir::Constant
|
2023-02-27 07:07:44 -06:00
|
|
|
// + span: $DIR/derefer_inline_test.rs:10:14: 10:15
|
|
|
|
// + literal: Const { ty: fn() -> Box<u32> {f}, val: Value(<ZST>) }
|
2022-05-11 16:27:06 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
bb1: {
|
2023-02-27 07:07:44 -06:00
|
|
|
_1 = Box::<Box<u32>>::new(move _2) -> [return: bb2, unwind: bb4]; // scope 0 at $DIR/derefer_inline_test.rs:+1:5: +1:18
|
2022-05-11 16:27:06 -05:00
|
|
|
// mir::Constant
|
2023-02-27 07:07:44 -06:00
|
|
|
// + span: $DIR/derefer_inline_test.rs:10:5: 10:13
|
|
|
|
// + user_ty: UserType(0)
|
|
|
|
// + literal: Const { ty: fn(Box<u32>) -> Box<Box<u32>> {Box::<Box<u32>>::new}, val: Value(<ZST>) }
|
2022-05-11 16:27:06 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
bb2: {
|
2023-02-27 07:07:44 -06:00
|
|
|
StorageDead(_2); // scope 0 at $DIR/derefer_inline_test.rs:+1:17: +1:18
|
|
|
|
drop(_1) -> bb3; // scope 0 at $DIR/derefer_inline_test.rs:+1:18: +1:19
|
2022-05-11 16:27:06 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
bb3: {
|
2023-02-27 07:07:44 -06:00
|
|
|
StorageDead(_1); // scope 0 at $DIR/derefer_inline_test.rs:+1:18: +1:19
|
2022-07-27 13:47:42 -05:00
|
|
|
_0 = const (); // scope 0 at $DIR/derefer_inline_test.rs:+0:11: +2:2
|
|
|
|
return; // scope 0 at $DIR/derefer_inline_test.rs:+2:2: +2:2
|
2022-05-11 16:27:06 -05:00
|
|
|
}
|
|
|
|
|
2023-02-27 07:07:44 -06:00
|
|
|
bb4 (cleanup): {
|
2023-04-05 03:17:40 -05:00
|
|
|
drop(_2) -> [return: bb5, unwind terminate]; // scope 0 at $DIR/derefer_inline_test.rs:+1:17: +1:18
|
2022-05-11 16:27:06 -05:00
|
|
|
}
|
|
|
|
|
2023-02-27 07:07:44 -06:00
|
|
|
bb5 (cleanup): {
|
2022-07-27 13:47:42 -05:00
|
|
|
resume; // scope 0 at $DIR/derefer_inline_test.rs:+0:1: +2:2
|
2022-05-11 16:27:06 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|