-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Make DatabaseProof trait stateful #15476
Copy link
Copy link
Closed
Labels
A-dbRelated to the databaseRelated to the databaseA-trieRelated to Merkle Patricia Trie implementationRelated to Merkle Patricia Trie implementationC-enhancementNew feature or requestNew feature or requestD-good-first-issueNice and easy! A great choice to get startedNice and easy! A great choice to get started
Metadata
Metadata
Assignees
Labels
A-dbRelated to the databaseRelated to the databaseA-trieRelated to Merkle Patricia Trie implementationRelated to Merkle Patricia Trie implementationC-enhancementNew feature or requestNew feature or requestD-good-first-issueNice and easy! A great choice to get startedNice and easy! A great choice to get started
Type
Projects
Status
Done
Describe the feature
Right now
DatabaseProofhas an associatedTXtype and takes&'a Self::TXon every method:reth/crates/trie/db/src/proof.rs
Lines 13 to 32 in db269f3
This is not necessary, instead we can make this into a regular trait that is stateful and takes
&self. For example it would look like:And the implementers (like
Proofetc) can have afrom_txmethod on the struct itselfAdditional context
No response