mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
chore(sdk): Add NodePrimitives::BlockHeader and NodePrimitives::BlockBody (#12647)
This commit is contained in:
@ -39,10 +39,21 @@ reth-codecs = { workspace = true, features = ["test-utils"] }
|
||||
rstest.workspace = true
|
||||
|
||||
[features]
|
||||
default = ["reth-codec"]
|
||||
default = ["std", "reth-codec"]
|
||||
std = [
|
||||
"reth-primitives-traits/std",
|
||||
"reth-primitives/std",
|
||||
"reth-node-types/std",
|
||||
"reth-codecs/std",
|
||||
"alloy-consensus/std",
|
||||
"alloy-eips/std",
|
||||
"alloy-primitives/std",
|
||||
"serde/std",
|
||||
]
|
||||
reth-codec = [
|
||||
"dep:reth-codecs",
|
||||
"reth-primitives/reth-codec"
|
||||
"reth-primitives/reth-codec",
|
||||
"reth-primitives-traits/reth-codec",
|
||||
]
|
||||
serde = [
|
||||
"dep:serde",
|
||||
|
||||
@ -6,21 +6,25 @@
|
||||
issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/"
|
||||
)]
|
||||
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]
|
||||
#![cfg_attr(not(feature = "std"), no_std)]
|
||||
|
||||
pub mod bedrock;
|
||||
pub mod tx_type;
|
||||
|
||||
pub use tx_type::OpTxType;
|
||||
|
||||
use reth_node_types::NodePrimitives;
|
||||
use reth_primitives::{Block, Receipt, TransactionSigned};
|
||||
use alloy_consensus::Header;
|
||||
use reth_node_types::FullNodePrimitives;
|
||||
use reth_primitives::{Block, BlockBody, Receipt, TransactionSigned};
|
||||
|
||||
/// Optimism primitive types.
|
||||
#[derive(Debug, Default, Clone, PartialEq, Eq)]
|
||||
pub struct OpPrimitives;
|
||||
|
||||
impl NodePrimitives for OpPrimitives {
|
||||
impl FullNodePrimitives for OpPrimitives {
|
||||
type Block = Block;
|
||||
type BlockHeader = Header;
|
||||
type BlockBody = BlockBody;
|
||||
type SignedTx = TransactionSigned;
|
||||
type TxType = OpTxType;
|
||||
type Receipt = Receipt;
|
||||
|
||||
Reference in New Issue
Block a user