Expand description
[revm] related types Helper types for working with [revm]
Re-exportsΒ§
use crate::mem::storage::MinedTransaction;πuse alloy_consensus::BlockBody;πuse alloy_eips::eip4895::Withdrawals;πuse alloy_eips::eip7928::BlockAccessList;πuse alloy_evm::block::BalIndexedDatabase;πuse alloy_network::Network;πuse alloy_primitives::Address;πuse alloy_primitives::B256;πuse alloy_primitives::Bytes;πuse alloy_primitives::U256;πuse alloy_primitives::keccak256;πuse alloy_primitives::map::AddressMap;πuse alloy_primitives::map::HashMap;πuse alloy_primitives::map::U256Map;πuse alloy_rpc_types::BlockId;πuse anvil_core::eth::block::Block;πuse anvil_core::eth::transaction::MaybeImpersonatedTransaction;πuse anvil_core::eth::transaction::TransactionInfo;πuse foundry_common::errors::FsPathError;πuse foundry_evm::backend::BlockchainDb;πuse foundry_evm::backend::DatabaseError;πuse foundry_evm::backend::DatabaseResult;πuse foundry_evm::backend::EmptyDBWrapper;πuse foundry_evm::backend::MemDb;πuse foundry_evm::backend::RevertStateSnapshotAction;πuse foundry_evm::backend::StateSnapshot;πuse foundry_evm::backend::existing_account;πuse foundry_primitives::FoundryHeader;πuse foundry_primitives::FoundryReceiptEnvelope;πuse foundry_primitives::FoundryTxEnvelope;πuse revm::Database;πuse revm::DatabaseCommit;πuse revm::bytecode::Bytecode;πuse revm::context::BlockEnv;πuse revm::context_interface::block::BlobExcessGasAndPrice;πuse revm::database::AccountState;πuse revm::database::CacheDB;πuse revm::database::DatabaseRef;πuse revm::database::DbAccount;πuse revm::database::bal::BalState;πuse revm::primitives::KECCAK_EMPTY;πuse revm::primitives::eip4844::BLOB_BASE_FEE_UPDATE_FRACTION_PRAGUE;πuse revm::primitives::hardfork::SpecId;πuse revm::state::AccountInfo;πuse revm::state::bal::BlockAccessIndex;πuse serde::Deserialize;πuse serde::Deserialize;πuse serde::Deserializer;πuse serde::Serialize;πuse serde::Serialize;πuse serde::de::Error as DeError;πuse serde::de::MapAccess;πuse serde::de::Visitor;πuse serde_json::Value;πuse std::collections::BTreeMap;πuse std::fmt;πuse std::fmt::Debug;πuse std::fmt::Debug;πuse std::fs::File;πuse std::io::BufReader;πuse std::path::Path;π
StructsΒ§
- Anvil
CacheDB - A wrapper around [
CacheDB] that executes transactions atspec. - Empty
AsAbsent πDb - A read-only view of a database that reports empty accounts as absent.
- Legacy
Blob Excess GasAnd Price - Legacy blob excess gas and price structure from before v1.3.
- Legacy
Block Env - Legacy block environment from before v1.3.
- Monad
Block Replay Profile monad - Execution inputs needed to replay a locally stored Monad block faithfully.
- Serializable
Account Record - Serializable
Block - Serializable
Historical States - Serializable
State - Serializable
Transaction - StateDb
- Represents a state at certain point
EnumsΒ§
- Serializable
Transaction Type - Defines a backwards-compatible enum for transactions. This is essential for maintaining compatibility with state dumps created before the changes introduced in PR #8411.
- String
OrU64 - Legacy string or u64 type from before v1.3.
ConstantsΒ§
- BLOCKHASH_
HISTORY π - Number of preceding block hashes available to the EVMβs
BLOCKHASHopcode.
TraitsΒ§
- Db
- This bundles all required revm traits
- Maybe
Forked Database - Helper trait to reset the DB if itβs forked
- Maybe
Full Database - Helper trait get access to the full state data of the database
FunctionsΒ§
- cache_
block_ πhash - Inserts a block hash, discards entries outside the EVM-visible cache, and returns its head.
- deserialize_
best_ πblock_ number_ compat - Custom deserializer for
best_block_numberthat handles both v1.2 and v1.3+ formats. - deserialize_
block_ πenv_ compat - Custom deserializer for
BlockEnvthat handles both v1.2 and v1.3+ formats. - deserialize_
btree π
Type AliasesΒ§
- State
Ref - A borrowed, type-erased state that overlays are built on, so that EVMs are monomorphized once.