clarify empty_nodes_mask documentation

This commit is contained in:
Grzegorz Świrski 2025-04-16 11:45:09 +02:00 committed by Qyriad
parent 8676326550
commit 0cc404c66f

View file

@ -25,6 +25,8 @@ use super::{
#[cfg_attr(feature = "serde", derive(serde::Deserialize, serde::Serialize))] #[cfg_attr(feature = "serde", derive(serde::Deserialize, serde::Serialize))]
pub struct SparseMerklePath { pub struct SparseMerklePath {
/// A bitmask representing empty nodes. The set bit corresponds to the depth of an empty node. /// A bitmask representing empty nodes. The set bit corresponds to the depth of an empty node.
/// The least significant bit (bit 0) describes depth 1 node (root's children).
/// The `bit index + 1` is equal to node's depth.
empty_nodes_mask: u64, empty_nodes_mask: u64,
/// The non-empty nodes, stored in depth-order, but not contiguous across depth. /// The non-empty nodes, stored in depth-order, but not contiguous across depth.
nodes: Vec<RpoDigest>, nodes: Vec<RpoDigest>,