Skip to content

Commit

Permalink
nargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
vezenovm committed Aug 26, 2024
1 parent cf6d370 commit 6b614e2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions noir_stdlib/src/hash/keccak.nr
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@ pub(crate) fn keccak256<let N: u32>(input: [u8; N], message_size: u32) -> [u8; 3
let num_limbs = max_blocks * LIMBS_PER_BLOCK; //max_blocks_length / WORD_SIZE;
for i in 0..num_limbs {
let mut temp = [0; WORD_SIZE];
let word_size_times_i = WORD_SIZE*i;
let word_size_times_i = WORD_SIZE * i;
for j in 0..WORD_SIZE {
temp[j] = block_bytes[word_size_times_i+j];
}
for j in 0..WORD_SIZE {
block_bytes[word_size_times_i + j] = temp[7 - j];
}
}

let mut sliced_buffer = Vec::new();
// populate a vector of 64-bit limbs from our byte array
for i in 0..num_limbs {
Expand Down Expand Up @@ -107,7 +107,7 @@ pub(crate) fn keccak256<let N: u32>(input: [u8; N], message_size: u32) -> [u8; 3
state[j] = state[j] ^ sliced_buffer.get(i * LIMBS_PER_BLOCK + j);
}
state = keccakf1600(state);
}
}
}
}

Expand Down

0 comments on commit 6b614e2

Please sign in to comment.