merkle_patricia_tree v0.2.8 MerklePatriciaTree.Trie.Destroyer
Destroyer is responsible for removing keys from a merkle trie. To remove a key, we need to make a delta to our trie which ends up as the canonical form of the given tree as defined in http://gavwood.com/Paper.pdf.
Note: this algorithm is non-obvious, and hence why we have a good number of functional and invariant tests. We should add more specific unit tests to this module.
Link to this section Summary
Functions
Removes a key from a given trie, if it exists.
Link to this section Functions
Link to this function
remove_key(trie_node, key, trie)
Removes a key from a given trie, if it exists.
This may radically change the structure of the trie.