revm_interpreter/
lib.rs

1//! # revm-interpreter
2//!
3//! Interpreter is part of the project that executes EVM instructions.
4#![cfg_attr(not(test), warn(unused_crate_dependencies))]
5#![cfg_attr(not(feature = "std"), no_std)]
6
7#[cfg(not(feature = "std"))]
8extern crate alloc as std;
9
10#[macro_use]
11mod macros;
12
13/// Gas calculation utilities and constants.
14pub mod gas;
15/// Context passed to instruction implementations.
16pub mod instruction_context;
17/// Instruction execution results and success/error types.
18mod instruction_result;
19/// EVM instruction implementations organized by category.
20pub mod instructions;
21/// Core interpreter implementation for EVM bytecode execution.
22pub mod interpreter;
23/// Types for interpreter actions like calls and contract creation.
24pub mod interpreter_action;
25/// Type traits and definitions for interpreter customization.
26pub mod interpreter_types;
27
28// Reexport primary types.
29pub use context_interface::{
30    context::{SStoreResult, SelfDestructResult, StateLoad},
31    CreateScheme,
32};
33pub use context_interface::{host, Host};
34pub use gas::{Gas, InitialAndFloorGas};
35pub use instruction_context::InstructionContext;
36pub use instruction_result::*;
37pub use instructions::{instruction_table, Instruction, InstructionTable};
38pub use interpreter::{
39    num_words, InputsImpl, Interpreter, InterpreterResult, SharedMemory, Stack, STACK_LIMIT,
40};
41pub use interpreter_action::{
42    CallInput, CallInputs, CallOutcome, CallScheme, CallValue, CreateInputs, CreateOutcome,
43    FrameInput, InterpreterAction,
44};
45pub use interpreter_types::InterpreterTypes;
46pub use primitives::{eip7907::MAX_CODE_SIZE, eip7907::MAX_INITCODE_SIZE};