Skip to main content

Module path

Module path 

Source
Expand description

Generic peak-to-leaf path iterator for Merkle-family data structures.

Iterator traverses the path from a peak to a leaf within a perfect binary tree, yielding (parent_pos, sibling_pos, height) tuples at each level. The traversal is top-down (peak first), using Family::children for child positions and leaf locations for the left/right decision at each level.

Structsยง

Iterator
Yields (parent_pos, sibling_pos, height) for each internal node on the path from a peak to a designated leaf, in top-down order (peak first). The peak itself is the first parent yielded; the leaf is never yielded.