Skip to content

Commit

Permalink
Update safety message
Browse files Browse the repository at this point in the history
  • Loading branch information
AurelienFT committed Jan 8, 2024
1 parent 3d71be9 commit d2dd35d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/trie/merkle_tree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ impl ProofNode {
ProofNode::Edge { child, path } => {
let mut bytes = [0u8; 32];
bytes.view_bits_mut::<Msb0>()[256 - path.0.len()..].copy_from_bitslice(&path.0);
// SAFETY: byte array is 32 bytes long
// SAFETY: path len is <= 251
let path_hash = Felt252Wrapper::try_from(&bytes).unwrap();

let length = Felt252Wrapper::from(path.0.len() as u8);
Expand Down

0 comments on commit d2dd35d

Please sign in to comment.