gballet / multiproof-rs

A rust implementation of Alexey Akhunov's multiproof algorithm
Apache License 2.0
33 stars 8 forks source link

Move make_multiproof/insert_leaf/rebuild to be a trait/impl on Node #22

Closed axic closed 5 years ago

s1na commented 5 years ago

make_multiproof and insert_leaf make sense if the Node is root, I'm not sure about rebuild though.

Alternative: add a Trie struct which has root: Node and define make_multiproof and insert_leaf on that?

gballet commented 5 years ago

Redundant with #8 #9 #10, closing

axic commented 5 years ago

@s1na why wouldn't rebuild make sense?

Node::rebuild_from_multiproof(&multiproof) -> Node, just like the ::new function.

s1na commented 5 years ago

@axic that'll work, you're right