mirror of
https://github.com/Qortal/pirate-librustzcash.git
synced 2025-02-14 10:45:47 +00:00
more idiomatic naming
This commit is contained in:
parent
443f45f430
commit
da0d0a669a
@ -39,8 +39,11 @@ impl Iterator for NodeDataIterator {
|
||||
|
||||
impl NodeDataIterator {
|
||||
pub fn new() -> Self {
|
||||
let mut root: Entry = NodeData::combine(&leaf(1), &leaf(2)).into();
|
||||
root.update_siblings(EntryLink::Stored(0), EntryLink::Stored(1));
|
||||
let root = Entry::new(
|
||||
NodeData::combine(&leaf(1), &leaf(2)),
|
||||
EntryLink::Stored(0),
|
||||
EntryLink::Stored(1)
|
||||
);
|
||||
let tree =
|
||||
Tree::new(
|
||||
3,
|
||||
|
@ -33,7 +33,7 @@ impl Entry {
|
||||
}
|
||||
|
||||
/// Is this node a leaf.
|
||||
pub fn is_leaf(&self) -> bool {
|
||||
pub fn leaf(&self) -> bool {
|
||||
if let EntryKind::Leaf = self.kind { true } else { false }
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user