Auto merge of #116724 - RalfJung:alloc-bytes, r=oli-obk
interpret: clean up AllocBytes Fixes https://github.com/rust-lang/miri/issues/2836 Nothing has moved here in half a year, so let's just remove these unused stubs -- they need a proper re-design anyway. r? `@oli-obk`
This commit is contained in:
commit
a00c09e9d8
2 changed files with 5 additions and 24 deletions
|
@ -538,17 +538,6 @@ impl<'mir, 'tcx: 'mir, M: Machine<'mir, 'tcx>> InterpCx<'mir, 'tcx, M> {
|
|||
)
|
||||
}
|
||||
|
||||
/// Get the base address for the bytes in an `Allocation` specified by the
|
||||
/// `AllocID` passed in; error if no such allocation exists.
|
||||
///
|
||||
/// It is up to the caller to take sufficient care when using this address:
|
||||
/// there could be provenance or uninit memory in there, and other memory
|
||||
/// accesses could invalidate the exposed pointer.
|
||||
pub fn alloc_base_addr(&self, id: AllocId) -> InterpResult<'tcx, *const u8> {
|
||||
let alloc = self.get_alloc_raw(id)?;
|
||||
Ok(alloc.base_addr())
|
||||
}
|
||||
|
||||
/// Gives raw access to the `Allocation`, without bounds or alignment checks.
|
||||
/// The caller is responsible for calling the access hooks!
|
||||
///
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue