@@ -224,12 +224,11 @@ impl<'tcx, Tag: Copy, Extra> Allocation<Tag, Extra> {
224224 cx : & impl HasDataLayout ,
225225 ptr : Pointer < Tag > ,
226226 size : Size ,
227- msg : CheckInAllocMsg ,
228227 ) -> EvalResult < ' tcx , & [ u8 ] >
229228 // FIXME: Working around https://github.com/rust-lang/rust/issues/56209
230229 where Extra : AllocationExtra < Tag , MemoryExtra >
231230 {
232- self . get_bytes_internal ( cx, ptr, size, true , msg )
231+ self . get_bytes_internal ( cx, ptr, size, true , CheckInAllocMsg :: MemoryAccess )
233232 }
234233
235234 /// It is the caller's responsibility to handle undefined and pointer bytes.
@@ -295,7 +294,7 @@ impl<'tcx, Tag: Copy, Extra> Allocation<Tag, Extra> {
295294 // Go through `get_bytes` for checks and AllocationExtra hooks.
296295 // We read the null, so we include it in the request, but we want it removed
297296 // from the result!
298- Ok ( & self . get_bytes ( cx, ptr, size_with_null, CheckInAllocMsg :: NullPointer ) ?[ ..size] )
297+ Ok ( & self . get_bytes ( cx, ptr, size_with_null) ?[ ..size] )
299298 }
300299 None => err ! ( UnterminatedCString ( ptr. erase_tag( ) ) ) ,
301300 }
@@ -379,7 +378,7 @@ impl<'tcx, Tag: Copy, Extra> Allocation<Tag, Extra> {
379378 {
380379 // get_bytes_unchecked tests relocation edges
381380 let bytes = self . get_bytes_with_undef_and_ptr ( cx, ptr, size,
382- CheckInAllocMsg :: PointerArithmetic ) ?;
381+ CheckInAllocMsg :: MemoryAccess ) ?;
383382 // Undef check happens *after* we established that the alignment is correct.
384383 // We must not return Ok() for unaligned pointers!
385384 if self . check_defined ( ptr, size) . is_err ( ) {
@@ -456,7 +455,7 @@ impl<'tcx, Tag: Copy, Extra> Allocation<Tag, Extra> {
456455 } ;
457456
458457 let endian = cx. data_layout ( ) . endian ;
459- let dst = self . get_bytes_mut ( cx, ptr, type_size, CheckInAllocMsg :: PointerArithmetic ) ?;
458+ let dst = self . get_bytes_mut ( cx, ptr, type_size, CheckInAllocMsg :: MemoryAccess ) ?;
460459 write_target_uint ( endian, dst, bytes) . unwrap ( ) ;
461460
462461 // See if we have to also write a relocation
0 commit comments