Function light_concurrent_merkle_tree::hash::compute_root
source · pub fn compute_root<H>(
leaf: &[u8; 32],
leaf_index: usize,
proof: &BoundedVec<[u8; 32]>,
) -> Result<[u8; 32], ConcurrentMerkleTreeError>where
H: Hasher,
Expand description
Computes the root for the given leaf
(with index i
) and proof
. It
doesn’t perform the validation of the provided proof
.