Trait EvmTr
pub trait EvmTr {
type Context: ContextTr;
type Instructions: InstructionProvider;
type Precompiles;
// Required methods
fn run_interpreter(
&mut self,
interpreter: &mut Interpreter<<Self::Instructions as InstructionProvider>::InterpreterTypes>,
) -> <<Self::Instructions as InstructionProvider>::InterpreterTypes as InterpreterTypes>::Output;
fn ctx(&mut self) -> &mut Self::Context;
fn ctx_ref(&self) -> &Self::Context;
fn ctx_instructions(
&mut self,
) -> (&mut Self::Context, &mut Self::Instructions);
fn ctx_precompiles(
&mut self,
) -> (&mut Self::Context, &mut Self::Precompiles);
}
Expand description
Main trait that combines the context, instructions and precompiles and allows execution of interpreter.
Required Associated Types§
Required Methods§
fn run_interpreter(
&mut self,
interpreter: &mut Interpreter<<Self::Instructions as InstructionProvider>::InterpreterTypes>,
) -> <<Self::Instructions as InstructionProvider>::InterpreterTypes as InterpreterTypes>::Output
fn run_interpreter( &mut self, interpreter: &mut Interpreter<<Self::Instructions as InstructionProvider>::InterpreterTypes>, ) -> <<Self::Instructions as InstructionProvider>::InterpreterTypes as InterpreterTypes>::Output
Run the interpreter loop and returns the output that can be a return or a next action.
fn ctx_instructions(&mut self) -> (&mut Self::Context, &mut Self::Instructions)
fn ctx_instructions(&mut self) -> (&mut Self::Context, &mut Self::Instructions)
Get the context and instructions.
fn ctx_precompiles(&mut self) -> (&mut Self::Context, &mut Self::Precompiles)
fn ctx_precompiles(&mut self) -> (&mut Self::Context, &mut Self::Precompiles)
Get the context and precompiles.