pub struct Evaluator<'mir, 'tcx> {Show 33 fields
pub stacked_borrows: Option<RefCell<GlobalStateInner>>,
pub data_race: Option<GlobalState>,
pub intptrcast: RefCell<GlobalStateInner>,
pub(crate) env_vars: EnvVars<'tcx>,
pub(crate) argc: Option<MemPlace<Provenance>>,
pub(crate) argv: Option<MemPlace<Provenance>>,
pub(crate) cmd_line: Option<MemPlace<Provenance>>,
pub(crate) tls: TlsData<'tcx>,
pub(crate) isolated_op: IsolatedOp,
pub(crate) validate: bool,
pub(crate) enforce_abi: bool,
pub(crate) file_handler: FileHandler,
pub(crate) dir_handler: DirHandler,
pub(crate) time_anchor: Instant,
pub(crate) threads: ThreadManager<'mir, 'tcx>,
pub(crate) layouts: PrimitiveLayouts<'tcx>,
pub(crate) static_roots: Vec<AllocId>,
profiler: Option<Profiler>,
string_cache: FxHashMap<String, StringId>,
pub(crate) exported_symbols_cache: FxHashMap<Symbol, Option<Instance<'tcx>>>,
pub(crate) panic_on_unsupported: bool,
pub(crate) backtrace_style: BacktraceStyle,
pub(crate) local_crates: Vec<CrateNum>,
extern_statics: FxHashMap<Symbol, Pointer<Provenance>>,
pub(crate) rng: RefCell<StdRng>,
tracked_alloc_ids: HashSet<AllocId>,
pub(crate) check_alignment: AlignmentCheck,
pub(crate) cmpxchg_weak_failure_rate: f64,
pub(crate) mute_stdout_stderr: bool,
pub(crate) weak_memory: bool,
pub(crate) preemption_rate: f64,
pub(crate) report_progress: Option<u32>,
pub(crate) since_progress_report: u32,
}Expand description
The machine itself.
Fields
stacked_borrows: Option<RefCell<GlobalStateInner>>data_race: Option<GlobalState>intptrcast: RefCell<GlobalStateInner>env_vars: EnvVars<'tcx>Environment variables set by setenv.
Miri does not expose env vars from the host to the emulated program.
argc: Option<MemPlace<Provenance>>Program arguments (Option because we can only initialize them after creating the ecx).
These are pointers to argc/argv because macOS.
We also need the full command line as one string because of Windows.
argv: Option<MemPlace<Provenance>>cmd_line: Option<MemPlace<Provenance>>tls: TlsData<'tcx>TLS state.
isolated_op: IsolatedOpWhat should Miri do when an op requires communicating with the host, such as accessing host env vars, random number generation, and file system access.
validate: boolWhether to enforce the validity invariant.
enforce_abi: boolWhether to enforce ABI of function calls.
file_handler: FileHandlerThe table of file descriptors.
dir_handler: DirHandlerThe table of directory descriptors.
time_anchor: InstantThe “time anchor” for this machine’s monotone clock (for Instant simulation).
threads: ThreadManager<'mir, 'tcx>The set of threads.
layouts: PrimitiveLayouts<'tcx>Precomputed TyLayouts for primitive data types that are commonly used inside Miri.
static_roots: Vec<AllocId>Allocations that are considered roots of static memory (that may leak).
profiler: Option<Profiler>The measureme profiler used to record timing information about
the emulated program.
string_cache: FxHashMap<String, StringId>Used with profiler to cache the StringIds for event names
uesd with measureme.
exported_symbols_cache: FxHashMap<Symbol, Option<Instance<'tcx>>>Cache of Instance exported under the given Symbol name.
None means no Instance exported under the given name is found.
panic_on_unsupported: boolWhether to raise a panic in the context of the evaluated process when unsupported
functionality is encountered. If false, an error is propagated in the Miri application context
instead (default behavior)
backtrace_style: BacktraceStyleEquivalent setting as RUST_BACKTRACE on encountering an error.
local_crates: Vec<CrateNum>Crates which are considered local for the purposes of error reporting.
extern_statics: FxHashMap<Symbol, Pointer<Provenance>>Mapping extern static names to their base pointer.
rng: RefCell<StdRng>The random number generator used for resolving non-determinism. Needs to be queried by ptr_to_int, hence needs interior mutability.
tracked_alloc_ids: HashSet<AllocId>The allocation IDs to report when they are being allocated (helps for debugging memory leaks and use after free bugs).
check_alignment: AlignmentCheckControls whether alignment of memory accesses is being checked.
cmpxchg_weak_failure_rate: f64Failure rate of compare_exchange_weak, between 0.0 and 1.0
mute_stdout_stderr: boolCorresponds to -Zmiri-mute-stdout-stderr and doesn’t write the output but acts as if it succeeded.
weak_memory: boolWhether weak memory emulation is enabled
preemption_rate: f64The probability of the active thread being preempted at the end of each basic block.
report_progress: Option<u32>If Some, we will report the current stack every N basic blocks.
since_progress_report: u32The number of blocks that passed since the last progress report.
Implementations
sourceimpl<'mir, 'tcx> Evaluator<'mir, 'tcx>
impl<'mir, 'tcx> Evaluator<'mir, 'tcx>
pub fn current_span(&self) -> CurrentSpan<'_, 'mir, 'tcx>
sourceimpl<'mir, 'tcx> Evaluator<'mir, 'tcx>
impl<'mir, 'tcx> Evaluator<'mir, 'tcx>
pub(crate) fn new(
config: &MiriConfig,
layout_cx: LayoutCx<'tcx, TyCtxt<'tcx>>
) -> Self
pub(crate) fn late_init(
this: &mut MiriEvalContext<'mir, 'tcx>,
config: &MiriConfig
) -> InterpResult<'tcx>
fn add_extern_static(
this: &mut MiriEvalContext<'mir, 'tcx>,
name: &str,
ptr: Pointer<Option<Provenance>>
)
sourcefn init_extern_statics(
this: &mut MiriEvalContext<'mir, 'tcx>
) -> InterpResult<'tcx>
fn init_extern_statics(
this: &mut MiriEvalContext<'mir, 'tcx>
) -> InterpResult<'tcx>
Sets up the “extern statics” for this machine.
pub(crate) fn communicate(&self) -> bool
Trait Implementations
sourceimpl<'mir, 'tcx> Machine<'mir, 'tcx> for Evaluator<'mir, 'tcx>
impl<'mir, 'tcx> Machine<'mir, 'tcx> for Evaluator<'mir, 'tcx>
Machine hook implementations.
sourcefn ptr_get_alloc(
ecx: &MiriEvalContext<'mir, 'tcx>,
ptr: Pointer<Self::Provenance>
) -> Option<(AllocId, Size, Self::ProvenanceExtra)>
fn ptr_get_alloc(
ecx: &MiriEvalContext<'mir, 'tcx>,
ptr: Pointer<Self::Provenance>
) -> Option<(AllocId, Size, Self::ProvenanceExtra)>
Convert a pointer with provenance into an allocation-offset pair,
or a None with an absolute address if that conversion is not possible.
type MemoryKind = MiriMemoryKind
type MemoryKind = MiriMemoryKind
Additional memory kinds a machine wishes to distinguish from the builtin ones
type ExtraFnVal = Dlsym
type ExtraFnVal = Dlsym
Machines can define extra (non-instance) things that represent values of function pointers.
For example, Miri uses this to return a function pointer from dlsym
that can later be called to execute the right thing. Read more
type FrameExtra = FrameData<'tcx>
type FrameExtra = FrameData<'tcx>
Extra data stored in every call frame.
type AllocExtra = AllocExtra
type AllocExtra = AllocExtra
Extra data stored in every allocation.
type Provenance = Provenance
type Provenance = Provenance
Pointers are “tagged” with provenance information; typically the AllocId they belong to.
type ProvenanceExtra = ProvenanceExtra
type ProvenanceExtra = ProvenanceExtra
When getting the AllocId of a pointer, some extra data is also obtained from the provenance that is passed to memory access hooks so they can do things with it. Read more
type MemoryMap = MonoHashMap<AllocId, (MemoryKind<MiriMemoryKind>, Allocation<Provenance, <Evaluator<'mir, 'tcx> as Machine<'mir, 'tcx>>::AllocExtra>)>
type MemoryMap = MonoHashMap<AllocId, (MemoryKind<MiriMemoryKind>, Allocation<Provenance, <Evaluator<'mir, 'tcx> as Machine<'mir, 'tcx>>::AllocExtra>)>
Memory’s allocation map
sourceconst GLOBAL_KIND: Option<MiriMemoryKind> = _
const GLOBAL_KIND: Option<MiriMemoryKind> = _
The memory kind to use for copied global memory (held in tcx) –
or None if such memory should not be mutated and thus any such attempt will cause
a ModifiedStatic error to be raised.
Statics are copied under two circumstances: When they are mutated, and when
adjust_allocation (see below) returns an owned allocation
that is added to the memory so that the work is not done twice. Read more
sourceconst PANIC_ON_ALLOC_FAIL: bool = false
const PANIC_ON_ALLOC_FAIL: bool = false
Should the machine panic on allocation failures?
sourcefn enforce_alignment(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
fn enforce_alignment(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
Whether memory accesses should be alignment-checked.
sourcefn force_int_for_alignment_check(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
fn force_int_for_alignment_check(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
Whether, when checking alignment, we should force_int and thus support
custom alignment logic based on whatever the integer address happens to be. Read more
sourcefn enforce_validity(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
fn enforce_validity(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
Whether to enforce the validity invariant
sourcefn enforce_number_init(_ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
fn enforce_number_init(_ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
Whether to enforce integers and floats being initialized.
sourcefn enforce_abi(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
fn enforce_abi(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
Whether function calls should be ABI-checked.
sourcefn checked_binop_checks_overflow(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
fn checked_binop_checks_overflow(ecx: &MiriEvalContext<'mir, 'tcx>) -> bool
Whether CheckedBinOp MIR statements should actually check for overflow.
sourcefn find_mir_or_eval_fn(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
instance: Instance<'tcx>,
abi: Abi,
args: &[OpTy<'tcx, Provenance>],
dest: &PlaceTy<'tcx, Provenance>,
ret: Option<BasicBlock>,
unwind: StackPopUnwind
) -> InterpResult<'tcx, Option<(&'mir Body<'tcx>, Instance<'tcx>)>>
fn find_mir_or_eval_fn(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
instance: Instance<'tcx>,
abi: Abi,
args: &[OpTy<'tcx, Provenance>],
dest: &PlaceTy<'tcx, Provenance>,
ret: Option<BasicBlock>,
unwind: StackPopUnwind
) -> InterpResult<'tcx, Option<(&'mir Body<'tcx>, Instance<'tcx>)>>
Entry point to all function calls. Read more
sourcefn call_extra_fn(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
fn_val: Dlsym,
abi: Abi,
args: &[OpTy<'tcx, Provenance>],
dest: &PlaceTy<'tcx, Provenance>,
ret: Option<BasicBlock>,
_unwind: StackPopUnwind
) -> InterpResult<'tcx>
fn call_extra_fn(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
fn_val: Dlsym,
abi: Abi,
args: &[OpTy<'tcx, Provenance>],
dest: &PlaceTy<'tcx, Provenance>,
ret: Option<BasicBlock>,
_unwind: StackPopUnwind
) -> InterpResult<'tcx>
Execute fn_val. It is the hook’s responsibility to advance the instruction
pointer as appropriate. Read more
sourcefn call_intrinsic(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
instance: Instance<'tcx>,
args: &[OpTy<'tcx, Provenance>],
dest: &PlaceTy<'tcx, Provenance>,
ret: Option<BasicBlock>,
unwind: StackPopUnwind
) -> InterpResult<'tcx>
fn call_intrinsic(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
instance: Instance<'tcx>,
args: &[OpTy<'tcx, Provenance>],
dest: &PlaceTy<'tcx, Provenance>,
ret: Option<BasicBlock>,
unwind: StackPopUnwind
) -> InterpResult<'tcx>
Directly process an intrinsic without pushing a stack frame. It is the hook’s responsibility to advance the instruction pointer as appropriate. Read more
sourcefn assert_panic(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
msg: &AssertMessage<'tcx>,
unwind: Option<BasicBlock>
) -> InterpResult<'tcx>
fn assert_panic(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
msg: &AssertMessage<'tcx>,
unwind: Option<BasicBlock>
) -> InterpResult<'tcx>
Called to evaluate Assert MIR terminators that trigger a panic.
sourcefn abort(
_ecx: &mut MiriEvalContext<'mir, 'tcx>,
msg: String
) -> InterpResult<'tcx, !>
fn abort(
_ecx: &mut MiriEvalContext<'mir, 'tcx>,
msg: String
) -> InterpResult<'tcx, !>
Called to evaluate Abort MIR terminator.
sourcefn binary_ptr_op(
ecx: &MiriEvalContext<'mir, 'tcx>,
bin_op: BinOp,
left: &ImmTy<'tcx, Provenance>,
right: &ImmTy<'tcx, Provenance>
) -> InterpResult<'tcx, (Scalar<Provenance>, bool, Ty<'tcx>)>
fn binary_ptr_op(
ecx: &MiriEvalContext<'mir, 'tcx>,
bin_op: BinOp,
left: &ImmTy<'tcx, Provenance>,
right: &ImmTy<'tcx, Provenance>
) -> InterpResult<'tcx, (Scalar<Provenance>, bool, Ty<'tcx>)>
Called for all binary operations where the LHS has pointer type. Read more
sourcefn thread_local_static_base_pointer(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
def_id: DefId
) -> InterpResult<'tcx, Pointer<Provenance>>
fn thread_local_static_base_pointer(
ecx: &mut MiriEvalContext<'mir, 'tcx>,
def_id: DefId
) -> InterpResult<'tcx, Pointer<Provenance>>
Return the AllocId for the given thread-local static in the current thread.
sourcefn extern_static_base_pointer(
ecx: &MiriEvalContext<'mir, 'tcx>,
def_id: DefId
) -> InterpResult<'tcx, Pointer<Provenance>>
fn extern_static_base_pointer(
ecx: &MiriEvalContext<'mir, 'tcx>,
def_id: DefId
) -> InterpResult<'tcx, Pointer<Provenance>>
Return the root pointer for the given extern static.
sourcefn adjust_allocation<'b>(
ecx: &MiriEvalContext<'mir, 'tcx>,
id: AllocId,
alloc: Cow<'b, Allocation>,
kind: Option<MemoryKind<Self::MemoryKind>>
) -> InterpResult<'tcx, Cow<'b, Allocation<Self::Provenance, Self::AllocExtra>>>
fn adjust_allocation<'b>(
ecx: &MiriEvalContext<'mir, 'tcx>,
id: AllocId,
alloc: Cow<'b, Allocation>,
kind: Option<MemoryKind<Self::MemoryKind>>
) -> InterpResult<'tcx, Cow<'b, Allocation<Self::Provenance, Self::AllocExtra>>>
Called to adjust allocations to the Provenance and AllocExtra of this machine. Read more
sourcefn adjust_alloc_base_pointer(
ecx: &MiriEvalContext<'mir, 'tcx>,
ptr: Pointer<AllocId>
) -> Pointer<Provenance>
fn adjust_alloc_base_pointer(
ecx: &MiriEvalContext<'mir, 'tcx>,
ptr: Pointer<AllocId>
) -> Pointer<Provenance>
Return a “base” pointer for the given allocation: the one that is used for direct accesses to this static/const/fn allocation, or the one returned from the heap allocator. Read more
sourcefn ptr_from_addr_cast(
ecx: &MiriEvalContext<'mir, 'tcx>,
addr: u64
) -> InterpResult<'tcx, Pointer<Option<Self::Provenance>>>
fn ptr_from_addr_cast(
ecx: &MiriEvalContext<'mir, 'tcx>,
addr: u64
) -> InterpResult<'tcx, Pointer<Option<Self::Provenance>>>
“Int-to-pointer cast”
sourcefn expose_ptr(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
ptr: Pointer<Self::Provenance>
) -> InterpResult<'tcx>
fn expose_ptr(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
ptr: Pointer<Self::Provenance>
) -> InterpResult<'tcx>
Marks a pointer as exposed, allowing it’s provenance to be recovered. “Pointer-to-int cast” Read more
sourcefn memory_read(
_tcx: TyCtxt<'tcx>,
machine: &Self,
alloc_extra: &AllocExtra,
(alloc_id, prov_extra): (AllocId, Self::ProvenanceExtra),
range: AllocRange
) -> InterpResult<'tcx>
fn memory_read(
_tcx: TyCtxt<'tcx>,
machine: &Self,
alloc_extra: &AllocExtra,
(alloc_id, prov_extra): (AllocId, Self::ProvenanceExtra),
range: AllocRange
) -> InterpResult<'tcx>
Hook for performing extra checks on a memory read access. Read more
sourcefn memory_written(
_tcx: TyCtxt<'tcx>,
machine: &mut Self,
alloc_extra: &mut AllocExtra,
(alloc_id, prov_extra): (AllocId, Self::ProvenanceExtra),
range: AllocRange
) -> InterpResult<'tcx>
fn memory_written(
_tcx: TyCtxt<'tcx>,
machine: &mut Self,
alloc_extra: &mut AllocExtra,
(alloc_id, prov_extra): (AllocId, Self::ProvenanceExtra),
range: AllocRange
) -> InterpResult<'tcx>
Hook for performing extra checks on a memory write access.
sourcefn memory_deallocated(
_tcx: TyCtxt<'tcx>,
machine: &mut Self,
alloc_extra: &mut AllocExtra,
(alloc_id, prove_extra): (AllocId, Self::ProvenanceExtra),
range: AllocRange
) -> InterpResult<'tcx>
fn memory_deallocated(
_tcx: TyCtxt<'tcx>,
machine: &mut Self,
alloc_extra: &mut AllocExtra,
(alloc_id, prove_extra): (AllocId, Self::ProvenanceExtra),
range: AllocRange
) -> InterpResult<'tcx>
Hook for performing extra operations on a memory deallocation.
sourcefn retag(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
kind: RetagKind,
place: &PlaceTy<'tcx, Provenance>
) -> InterpResult<'tcx>
fn retag(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
kind: RetagKind,
place: &PlaceTy<'tcx, Provenance>
) -> InterpResult<'tcx>
Executes a retagging operation.
sourcefn init_frame_extra(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
frame: Frame<'mir, 'tcx, Provenance>
) -> InterpResult<'tcx, Frame<'mir, 'tcx, Provenance, FrameData<'tcx>>>
fn init_frame_extra(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
frame: Frame<'mir, 'tcx, Provenance>
) -> InterpResult<'tcx, Frame<'mir, 'tcx, Provenance, FrameData<'tcx>>>
Called immediately before a new stack frame gets pushed.
sourcefn stack<'a>(
ecx: &'a InterpCx<'mir, 'tcx, Self>
) -> &'a [Frame<'mir, 'tcx, Self::Provenance, Self::FrameExtra>]
fn stack<'a>(
ecx: &'a InterpCx<'mir, 'tcx, Self>
) -> &'a [Frame<'mir, 'tcx, Self::Provenance, Self::FrameExtra>]
Borrow the current thread’s stack.
sourcefn stack_mut<'a>(
ecx: &'a mut InterpCx<'mir, 'tcx, Self>
) -> &'a mut Vec<Frame<'mir, 'tcx, Self::Provenance, Self::FrameExtra>>
fn stack_mut<'a>(
ecx: &'a mut InterpCx<'mir, 'tcx, Self>
) -> &'a mut Vec<Frame<'mir, 'tcx, Self::Provenance, Self::FrameExtra>>
Mutably borrow the current thread’s stack.
sourcefn before_terminator(ecx: &mut InterpCx<'mir, 'tcx, Self>) -> InterpResult<'tcx>
fn before_terminator(ecx: &mut InterpCx<'mir, 'tcx, Self>) -> InterpResult<'tcx>
Called before a basic block terminator is executed. You can use this to detect endlessly running programs. Read more
sourcefn after_stack_push(ecx: &mut InterpCx<'mir, 'tcx, Self>) -> InterpResult<'tcx>
fn after_stack_push(ecx: &mut InterpCx<'mir, 'tcx, Self>) -> InterpResult<'tcx>
Called immediately after a stack frame got pushed and its locals got initialized.
sourcefn after_stack_pop(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
frame: Frame<'mir, 'tcx, Provenance, FrameData<'tcx>>,
unwinding: bool
) -> InterpResult<'tcx, StackPopJump>
fn after_stack_pop(
ecx: &mut InterpCx<'mir, 'tcx, Self>,
frame: Frame<'mir, 'tcx, Provenance, FrameData<'tcx>>,
unwinding: bool
) -> InterpResult<'tcx, StackPopJump>
Called immediately after a stack frame got popped, but before jumping back to the caller.
The locals have already been destroyed! Read more
sourcefn load_mir(
ecx: &InterpCx<'mir, 'tcx, Self>,
instance: InstanceDef<'tcx>
) -> Result<&'tcx Body<'tcx>, InterpErrorInfo<'tcx>>
fn load_mir(
ecx: &InterpCx<'mir, 'tcx, Self>,
instance: InstanceDef<'tcx>
) -> Result<&'tcx Body<'tcx>, InterpErrorInfo<'tcx>>
Entry point for obtaining the MIR of anything that should get evaluated. So not just functions and shims, but also const/static initializers, anonymous constants, … Read more
sourcefn access_local(
frame: &'a Frame<'mir, 'tcx, Self::Provenance, Self::FrameExtra>,
local: Local
) -> Result<&'a Operand<Self::Provenance>, InterpErrorInfo<'tcx>> where
'tcx: 'mir,
fn access_local(
frame: &'a Frame<'mir, 'tcx, Self::Provenance, Self::FrameExtra>,
local: Local
) -> Result<&'a Operand<Self::Provenance>, InterpErrorInfo<'tcx>> where
'tcx: 'mir,
Called to read the specified local from the frame.
Since reading a ZST is not actually accessing memory or locals, this is never invoked
for ZST reads. Read more
sourcefn access_local_mut(
ecx: &'a mut InterpCx<'mir, 'tcx, Self>,
frame: usize,
local: Local
) -> Result<&'a mut Operand<Self::Provenance>, InterpErrorInfo<'tcx>> where
'tcx: 'mir,
fn access_local_mut(
ecx: &'a mut InterpCx<'mir, 'tcx, Self>,
frame: usize,
local: Local
) -> Result<&'a mut Operand<Self::Provenance>, InterpErrorInfo<'tcx>> where
'tcx: 'mir,
Called to write the specified local from the frame.
Since writing a ZST is not actually accessing memory or locals, this is never invoked
for ZST reads. Read more
sourcefn before_access_global(
_tcx: TyCtxt<'tcx>,
_machine: &Self,
_alloc_id: AllocId,
_allocation: ConstAllocation<'tcx, AllocId, ()>,
_static_def_id: Option<DefId>,
_is_write: bool
) -> Result<(), InterpErrorInfo<'tcx>>
fn before_access_global(
_tcx: TyCtxt<'tcx>,
_machine: &Self,
_alloc_id: AllocId,
_allocation: ConstAllocation<'tcx, AllocId, ()>,
_static_def_id: Option<DefId>,
_is_write: bool
) -> Result<(), InterpErrorInfo<'tcx>>
Called before a global allocation is accessed.
def_id is Some if this is the “lazy” allocation of a static. Read more
Auto Trait Implementations
impl<'mir, 'tcx> !RefUnwindSafe for Evaluator<'mir, 'tcx>
impl<'mir, 'tcx> !Send for Evaluator<'mir, 'tcx>
impl<'mir, 'tcx> !Sync for Evaluator<'mir, 'tcx>
impl<'mir, 'tcx> Unpin for Evaluator<'mir, 'tcx> where
'tcx: 'mir,
impl<'mir, 'tcx> !UnwindSafe for Evaluator<'mir, 'tcx>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
Layout
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference’s “Type Layout” chapter for details on type layout guarantees.
Size: 2112 bytes