chore: rm reth_primitives from reth_revm (#14317)

This commit is contained in:
Dan Cline
2025-02-08 01:08:20 -05:00
committed by GitHub
parent d99f0fa5ae
commit 44985c3272
5 changed files with 14 additions and 9 deletions

3
Cargo.lock generated
View File

@ -8821,7 +8821,8 @@ dependencies = [
"alloy-eips",
"alloy-primitives",
"reth-ethereum-forks",
"reth-primitives",
"reth-ethereum-primitives",
"reth-primitives-traits",
"reth-storage-api",
"reth-storage-errors",
"reth-trie",

View File

@ -13,7 +13,8 @@ workspace = true
[dependencies]
# reth
reth-primitives.workspace = true
reth-primitives-traits.workspace = true
reth-ethereum-primitives.workspace = true
reth-storage-errors.workspace = true
reth-storage-api.workspace = true
reth-trie = { workspace = true, optional = true }
@ -34,19 +35,21 @@ alloy-consensus.workspace = true
[features]
default = ["std"]
std = [
"reth-primitives/std",
"reth-primitives-traits/std",
"alloy-primitives/std",
"revm/std",
"alloy-eips/std",
"alloy-consensus/std",
"reth-ethereum-forks/std",
"reth-ethereum-primitives/std",
]
witness = ["dep:reth-trie"]
test-utils = [
"dep:reth-trie",
"reth-primitives/test-utils",
"reth-primitives-traits/test-utils",
"reth-trie?/test-utils",
"revm/test-utils",
"reth-ethereum-primitives/test-utils",
]
serde = [
"revm/serde",
@ -55,4 +58,5 @@ serde = [
"alloy-consensus/serde",
"reth-trie?/serde",
"reth-ethereum-forks/serde",
"reth-primitives-traits/serde",
]

View File

@ -10,7 +10,7 @@ use alloy_primitives::BlockNumber;
/// - pruning receipts according to the pruning configuration.
/// - batch range if known
#[derive(Debug)]
pub struct BlockBatchRecord<T = reth_primitives::Receipt> {
pub struct BlockBatchRecord<T = reth_ethereum_primitives::Receipt> {
/// The collection of receipts.
/// Outer vector stores receipts for each block sequentially.
/// The inner vector stores receipts ordered by transaction number.

View File

@ -1,7 +1,7 @@
use crate::primitives::alloy_primitives::{BlockNumber, StorageKey, StorageValue};
use alloy_primitives::{Address, B256, U256};
use core::ops::{Deref, DerefMut};
use reth_primitives::Account;
use reth_primitives_traits::Account;
use reth_storage_api::{AccountReader, BlockHashReader, StateProvider};
use reth_storage_errors::provider::{ProviderError, ProviderResult};
use revm::{
@ -27,7 +27,7 @@ pub trait EvmStateProvider: Send + Sync {
fn bytecode_by_hash(
&self,
code_hash: &B256,
) -> ProviderResult<Option<reth_primitives::Bytecode>>;
) -> ProviderResult<Option<reth_primitives_traits::Bytecode>>;
/// Get storage of the given account.
fn storage(
@ -50,7 +50,7 @@ impl<T: StateProvider> EvmStateProvider for T {
fn bytecode_by_hash(
&self,
code_hash: &B256,
) -> ProviderResult<Option<reth_primitives::Bytecode>> {
) -> ProviderResult<Option<reth_primitives_traits::Bytecode>> {
<T as StateProvider>::bytecode_by_hash(self, code_hash)
}

View File

@ -4,7 +4,7 @@ use alloy_primitives::{
map::{B256HashMap, HashMap},
Address, BlockNumber, Bytes, StorageKey, B256, U256,
};
use reth_primitives::{Account, Bytecode};
use reth_primitives_traits::{Account, Bytecode};
use reth_storage_api::{
AccountReader, BlockHashReader, HashedPostStateProvider, StateProofProvider, StateProvider,
StateRootProvider, StorageRootProvider,