chore(sdk): Add NodePrimitives::BlockHeader and NodePrimitives::BlockBody (#12647)

This commit is contained in:
Emilia Hane
2024-11-21 18:03:05 +01:00
committed by GitHub
parent 2c7b404c24
commit 2093d2bd9a
9 changed files with 68 additions and 31 deletions

View File

@ -79,17 +79,10 @@ pub mod serde_bincode_compat {
#[derive(Debug, Clone, Default, PartialEq, Eq, serde::Serialize, serde::Deserialize)]
pub struct EthPrimitives;
#[cfg(feature = "reth-codec")]
impl reth_primitives_traits::FullNodePrimitives for EthPrimitives {
type Block = crate::Block;
type SignedTx = crate::TransactionSigned;
type TxType = crate::TxType;
type Receipt = crate::Receipt;
}
#[cfg(not(feature = "reth-codec"))]
impl NodePrimitives for EthPrimitives {
type Block = crate::Block;
type BlockHeader = alloy_consensus::Header;
type BlockBody = crate::BlockBody;
type SignedTx = crate::TransactionSigned;
type TxType = crate::TxType;
type Receipt = crate::Receipt;