Trait rustc_mir::interpret::HasMemory
[−]
[src]
pub trait HasMemory<'a, 'tcx: 'a, M: Machine<'tcx>> {
fn memory_mut(&mut self) -> &mut Memory<'a, 'tcx, M>;
fn memory(&self) -> &Memory<'a, 'tcx, M>;
fn read_maybe_aligned<F, T>(
&self,
aligned: bool,
f: F
) -> EvalResult<'tcx, T>
where
F: FnOnce(&Self) -> EvalResult<'tcx, T>,
{ ... }
fn read_maybe_aligned_mut<F, T>(
&mut self,
aligned: bool,
f: F
) -> EvalResult<'tcx, T>
where
F: FnOnce(&mut Self) -> EvalResult<'tcx, T>,
{ ... }
fn write_maybe_aligned_mut<F, T>(
&mut self,
aligned: bool,
f: F
) -> EvalResult<'tcx, T>
where
F: FnOnce(&mut Self) -> EvalResult<'tcx, T>,
{ ... }
fn into_ptr(&self, value: Value) -> EvalResult<'tcx, Pointer> { ... }
fn into_ptr_vtable_pair(
&self,
value: Value
) -> EvalResult<'tcx, (Pointer, MemoryPointer)> { ... }
fn into_slice(&self, value: Value) -> EvalResult<'tcx, (Pointer, u64)> { ... }
}🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Required Methods
fn memory_mut(&mut self) -> &mut Memory<'a, 'tcx, M>
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
fn memory(&self) -> &Memory<'a, 'tcx, M>
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Provided Methods
fn read_maybe_aligned<F, T>(&self, aligned: bool, f: F) -> EvalResult<'tcx, T> where
F: FnOnce(&Self) -> EvalResult<'tcx, T>,
F: FnOnce(&Self) -> EvalResult<'tcx, T>,
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
fn read_maybe_aligned_mut<F, T>(
&mut self,
aligned: bool,
f: F
) -> EvalResult<'tcx, T> where
F: FnOnce(&mut Self) -> EvalResult<'tcx, T>,
&mut self,
aligned: bool,
f: F
) -> EvalResult<'tcx, T> where
F: FnOnce(&mut Self) -> EvalResult<'tcx, T>,
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
fn write_maybe_aligned_mut<F, T>(
&mut self,
aligned: bool,
f: F
) -> EvalResult<'tcx, T> where
F: FnOnce(&mut Self) -> EvalResult<'tcx, T>,
&mut self,
aligned: bool,
f: F
) -> EvalResult<'tcx, T> where
F: FnOnce(&mut Self) -> EvalResult<'tcx, T>,
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
fn into_ptr(&self, value: Value) -> EvalResult<'tcx, Pointer>
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Convert the value into a pointer (or a pointer-sized integer). If the value is a ByRef, this may have to perform a load.
fn into_ptr_vtable_pair(
&self,
value: Value
) -> EvalResult<'tcx, (Pointer, MemoryPointer)>
&self,
value: Value
) -> EvalResult<'tcx, (Pointer, MemoryPointer)>
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
fn into_slice(&self, value: Value) -> EvalResult<'tcx, (Pointer, u64)>
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Implementors
impl<'a, 'tcx, M: Machine<'tcx>> HasMemory<'a, 'tcx, M> for Memory<'a, 'tcx, M>impl<'a, 'tcx, M: Machine<'tcx>> HasMemory<'a, 'tcx, M> for EvalContext<'a, 'tcx, M>