mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
chore: remove serde support from reth-codec (#9570)
This commit is contained in:
@ -2,6 +2,7 @@
|
||||
|
||||
use reth_codecs::{reth_codec, Compact};
|
||||
use reth_primitives::{Header, TxNumber, Withdrawals, B256};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::ops::Range;
|
||||
|
||||
/// Total number of transactions.
|
||||
@ -11,7 +12,7 @@ pub type NumTransactions = u64;
|
||||
///
|
||||
/// It has the pointer to the transaction Number of the first
|
||||
/// transaction in the block and the total number of transactions.
|
||||
#[derive(Debug, Default, Eq, PartialEq, Clone)]
|
||||
#[derive(Debug, Default, Eq, PartialEq, Clone, Serialize, Deserialize)]
|
||||
#[reth_codec]
|
||||
pub struct StoredBlockBodyIndices {
|
||||
/// The number of the first transaction in this block
|
||||
@ -69,7 +70,7 @@ impl StoredBlockBodyIndices {
|
||||
///
|
||||
/// It is stored as the headers of the block's uncles.
|
||||
#[reth_codec]
|
||||
#[derive(Debug, Default, Eq, PartialEq, Clone)]
|
||||
#[derive(Debug, Default, Eq, PartialEq, Clone, Serialize, Deserialize)]
|
||||
pub struct StoredBlockOmmers {
|
||||
/// The block headers of this block's uncles.
|
||||
pub ommers: Vec<Header>,
|
||||
@ -77,7 +78,7 @@ pub struct StoredBlockOmmers {
|
||||
|
||||
/// The storage representation of block withdrawals.
|
||||
#[reth_codec]
|
||||
#[derive(Debug, Default, Eq, PartialEq, Clone)]
|
||||
#[derive(Debug, Default, Eq, PartialEq, Clone, Serialize, Deserialize)]
|
||||
pub struct StoredBlockWithdrawals {
|
||||
/// The block withdrawals.
|
||||
pub withdrawals: Withdrawals,
|
||||
|
||||
@ -9,6 +9,7 @@ use reth_primitives::{Address, B256, *};
|
||||
use reth_prune_types::{PruneCheckpoint, PruneSegment};
|
||||
use reth_stages_types::StageCheckpoint;
|
||||
use reth_trie_common::{StoredNibbles, StoredNibblesSubKey, *};
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
pub mod accounts;
|
||||
pub mod blocks;
|
||||
@ -264,7 +265,7 @@ macro_rules! add_wrapper_struct {
|
||||
$(
|
||||
/// Wrapper struct so it can use StructFlags from Compact, when used as pure table values.
|
||||
#[reth_codec]
|
||||
#[derive(Debug, Clone, PartialEq, Eq, Default)]
|
||||
#[derive(Debug, Clone, PartialEq, Eq, Default, Serialize, Deserialize)]
|
||||
pub struct $wrapper(pub $name);
|
||||
|
||||
impl From<$name> for $wrapper {
|
||||
|
||||
Reference in New Issue
Block a user