verify_update

Function verify_update 

Source
pub fn verify_update<H: NodeHasher>(
    prev_root: Node,
    paths: &[PathUpdate],
) -> Result<Node, VerifyUpdateError>
Expand description

Verify an update operation against the root node. This follows a similar algorithm to the multi-item update, but without altering any backing storage.

Paths should be ascending, ops should be ascending, all ops should look up to one of the paths in paths.

All paths should share the same root.

Returns the root of the trie obtained after application of the given updates in the paths vector. In case the paths is empty, prev_root is returned.