pub trait InstructionDriverPolicy<P, F>where
P: InstructionPolicy,{
type Return;
type Abrupt;
type Yield;
type Interrupt;
type Fault;
// Required method
fn step(
&mut self,
instruction: &P::Instruction,
frame: &mut F,
) -> PolicyStep<F, Self::Return, Self::Abrupt, Self::Yield, Self::Interrupt, Self::Fault>;
}Expand description
Consumer semantics invoked once per charged instruction.
A WebAssembly engine or a bytecode-independent workflow machine can supply this policy. The callback cannot run until admission identity is checked.
Required Associated Types§
Required Methods§
Sourcefn step(
&mut self,
instruction: &P::Instruction,
frame: &mut F,
) -> PolicyStep<F, Self::Return, Self::Abrupt, Self::Yield, Self::Interrupt, Self::Fault>
fn step( &mut self, instruction: &P::Instruction, frame: &mut F, ) -> PolicyStep<F, Self::Return, Self::Abrupt, Self::Yield, Self::Interrupt, Self::Fault>
Executes one instruction policy and returns an explicit control outcome.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".