File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ use core::hint;
14
14
use core:: intrinsics:: abort;
15
15
use core:: iter;
16
16
use core:: marker:: { PhantomData , Unpin , Unsize } ;
17
- use core:: mem:: { self , align_of_val , size_of_val} ;
17
+ use core:: mem:: { self , align_of_val_raw , size_of_val} ;
18
18
use core:: ops:: { CoerceUnsized , Deref , DispatchFromDyn , Receiver } ;
19
19
use core:: pin:: Pin ;
20
20
use core:: ptr:: { self , NonNull } ;
@@ -2366,7 +2366,7 @@ unsafe fn data_offset<T: ?Sized>(ptr: *const T) -> isize {
2366
2366
// Because it is `?Sized`, it will always be the last field in memory.
2367
2367
// Note: This is a detail of the current implementation of the compiler,
2368
2368
// and is not a guaranteed language detail. Do not rely on it outside of std.
2369
- unsafe { data_offset_align ( align_of_val ( & * ptr) ) }
2369
+ unsafe { data_offset_align ( align_of_val_raw ( ptr) ) }
2370
2370
}
2371
2371
2372
2372
#[ inline]
You can’t perform that action at this time.
0 commit comments