File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ use core::hint;
1414use core:: intrinsics:: abort;
1515use core:: iter;
1616use 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} ;
1818use core:: ops:: { CoerceUnsized , Deref , DispatchFromDyn , Receiver } ;
1919use core:: pin:: Pin ;
2020use core:: ptr:: { self , NonNull } ;
@@ -2364,7 +2364,7 @@ unsafe fn data_offset<T: ?Sized>(ptr: *const T) -> isize {
23642364 // Because it is `?Sized`, it will always be the last field in memory.
23652365 // Note: This is a detail of the current implementation of the compiler,
23662366 // and is not a guaranteed language detail. Do not rely on it outside of std.
2367- unsafe { data_offset_align ( align_of_val ( & * ptr) ) }
2367+ unsafe { data_offset_align ( align_of_val_raw ( ptr) ) }
23682368}
23692369
23702370#[ inline]
You can’t perform that action at this time.
0 commit comments