/// A utility to build a fork node.
A utility to build a fork node.
A utility to build a fork node .
fn fork(hash: [u8; 32], children_vec: Vec<(&str, RoseHashTree)>) -> RoseHashTree {
        let children = children_vec
            .into_iter()
            .map(|(s, t)| (s.into_label(), t))
            .collect();
        RoseHashTree::Fork {
            digest: Digest(hash),
            children,
        }
    }
fn fork ( hash : [ u8 ; 32 ] , children_vec : Vec < ( & str , RoseHashTree ) > ) -> RoseHashTree { let children = children_vec . into_iter ( ) . map ( | ( s , t ) | ( s . into_label ( ) , t ) ) . collect ( ) ; RoseHashTree :: Fork { digest : Digest ( hash ) , children , } }
A utility to build a fork node.
A utility to build a fork node .
hash
[u8; 32]
children_vec
Vec<(&str, RoseHashTree)>