2 // compile-flags:-Zprint-mono-items=eager
3 // compile-flags:-Zinline-in-all-cgus
7 //~ MONO_ITEM fn std::ptr::drop_in_place::<StructWithDtor> - shim(Some(StructWithDtor)) @@ drop_in_place_intrinsic-cgu.0[Internal]
8 struct StructWithDtor(u32);
10 impl Drop for StructWithDtor {
11 //~ MONO_ITEM fn <StructWithDtor as std::ops::Drop>::drop
15 //~ MONO_ITEM fn start
17 fn start(_: isize, _: *const *const u8) -> isize {
19 //~ MONO_ITEM fn std::ptr::drop_in_place::<[StructWithDtor; 2]> - shim(Some([StructWithDtor; 2])) @@ drop_in_place_intrinsic-cgu.0[Internal]
20 let x = [StructWithDtor(0), StructWithDtor(1)];
22 drop_slice_in_place(&x);
27 //~ MONO_ITEM fn drop_slice_in_place
28 fn drop_slice_in_place(x: &[StructWithDtor]) {
30 // This is the interesting thing in this test case: Normally we would
31 // not have drop-glue for the unsized [StructWithDtor]. This has to be
32 // generated though when the drop_in_place() intrinsic is used.
33 //~ MONO_ITEM fn std::ptr::drop_in_place::<[StructWithDtor]> - shim(Some([StructWithDtor])) @@ drop_in_place_intrinsic-cgu.0[Internal]
34 ::std::ptr::drop_in_place(x as *const _ as *mut [StructWithDtor]);