Compare commits

...

1 Commits

Author SHA1 Message Date
Arsenii Kulikov
bb9837e2f9 wip 2026-02-21 01:18:35 +04:00
2 changed files with 6 additions and 6 deletions

View File

@@ -857,7 +857,7 @@ impl SparseTrie for ParallelSparseTrie {
SparseNode::Branch {
state_mask,
blinded_mask,
blinded_hashes: blinded_hashes.clone(),
blinded_hashes: *blinded_hashes,
state: SparseNodeState::Dirty,
}
};
@@ -1228,7 +1228,7 @@ impl SparseTrie for ParallelSparseTrie {
// For branch nodes at max depth, collapse all children onto them,
if depth == max_depth {
let mut blinded_mask = *blinded_mask;
let mut blinded_hashes = blinded_hashes.clone();
let mut blinded_hashes = *blinded_hashes;
for nibble in state_mask.iter() {
if blinded_mask.is_bit_set(nibble) {
continue;
@@ -2712,7 +2712,7 @@ impl SparseSubtrie {
};
let mut blinded_mask = TrieMask::default();
let mut blinded_hashes = Box::new([B256::ZERO; 16]);
let mut blinded_hashes = [B256::ZERO; 16];
for (stack_ptr, idx) in state_mask.iter().enumerate() {
let mut child_path = path;

View File

@@ -358,7 +358,7 @@ pub enum SparseNode {
/// The mask of the children that are blinded.
blinded_mask: TrieMask,
/// The hashes of the children that are blinded.
blinded_hashes: Box<[B256; 16]>,
blinded_hashes: [B256; 16],
},
}
@@ -367,7 +367,7 @@ impl SparseNode {
#[cfg(test)]
pub fn new_branch(state_mask: TrieMask, blinded_children: &[(u8, B256)]) -> Self {
let mut blinded_mask = TrieMask::default();
let mut blinded_hashes = Box::new([B256::ZERO; 16]);
let mut blinded_hashes = [B256::ZERO; 16];
for (nibble, hash) in blinded_children {
blinded_mask.set_bit(*nibble);
@@ -386,7 +386,7 @@ impl SparseNode {
state_mask,
state: SparseNodeState::Dirty,
blinded_mask: TrieMask::default(),
blinded_hashes: Box::new([B256::ZERO; 16]),
blinded_hashes: [B256::ZERO; 16],
}
}