feat : add storage_root provider function for account (#9659)

Co-authored-by: Roman Krasiuk <rokrassyuk@gmail.com>
This commit is contained in:
nk_ysg
2024-08-02 15:19:12 +08:00
committed by GitHub
parent db2ece8d08
commit 44028076ff
15 changed files with 202 additions and 27 deletions

View File

@ -6,7 +6,7 @@ use reth_storage_api::{
AccountReader, BlockHashReader, StateProofProvider, StateProvider, StateRootProvider,
};
use reth_storage_errors::provider::ProviderResult;
use reth_trie::{updates::TrieUpdates, AccountProof, HashedPostState};
use reth_trie::{updates::TrieUpdates, AccountProof, HashedPostState, HashedStorage};
#[cfg(not(feature = "std"))]
use alloc::vec::Vec;
@ -78,6 +78,14 @@ impl StateRootProvider for StateProviderTest {
) -> ProviderResult<(B256, TrieUpdates)> {
unimplemented!("state root computation is not supported")
}
fn hashed_storage_root(
&self,
_address: Address,
_hashed_storage: HashedStorage,
) -> ProviderResult<B256> {
unimplemented!("storage root is not supported")
}
}
impl StateProofProvider for StateProviderTest {