Skip to content

Commit 5f2bdc2

Browse files
authored
feat: add deref for block (#1868)
1 parent 7fe5ea0 commit 5f2bdc2

File tree

1 file changed

+2
-1
lines changed
  • crates/consensus/src/block

1 file changed

+2
-1
lines changed

crates/consensus/src/block/mod.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,11 @@ use alloy_rlp::{Decodable, Encodable, RlpDecodable, RlpEncodable};
1919
/// Taken from [reth-primitives](https://github.com/paradigmxyz/reth)
2020
///
2121
/// See p2p block encoding reference: <https://github.com/ethereum/devp2p/blob/master/caps/eth.md#block-encoding-and-validity>
22-
#[derive(Debug, Clone, PartialEq, Eq)]
22+
#[derive(Debug, Clone, PartialEq, Eq, derive_more::Deref)]
2323
#[cfg_attr(any(test, feature = "serde"), derive(serde::Serialize, serde::Deserialize))]
2424
pub struct Block<T, H = Header> {
2525
/// Block header.
26+
#[deref]
2627
pub header: H,
2728
/// Block body.
2829
pub body: BlockBody<T>,

0 commit comments

Comments
 (0)