From 7abff837c5fee2a1091bde9dca0a1f04aaa08085 Mon Sep 17 00:00:00 2001 From: Jack Nelson Date: Sat, 3 Aug 2024 02:52:07 -0400 Subject: [PATCH] fix fmt --- benches/sha256_hash.rs | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/benches/sha256_hash.rs b/benches/sha256_hash.rs index f2775c8d..411e56ee 100644 --- a/benches/sha256_hash.rs +++ b/benches/sha256_hash.rs @@ -1,4 +1,4 @@ -use criterion::{criterion_group, criterion_main, Criterion, black_box}; +use criterion::{black_box, criterion_group, criterion_main, Criterion}; use clvmr::sha2::Sha256; @@ -24,14 +24,16 @@ fn sha256_hash_benchmark(c: &mut Criterion) { let mut group = c.benchmark_group("sha256_hash"); group.bench_function("hash_benchmark", |b| { - b.iter(|| { black_box( - // this figures out how many iterations to run. - for val in 0..MAX_VAL { - for len in BYTE_LENGTHS { - let bytes = gen_bytes(val, len); - hash_bytes(&bytes); - } - }) + b.iter(|| { + black_box( + // this figures out how many iterations to run. + for val in 0..MAX_VAL { + for len in BYTE_LENGTHS { + let bytes = gen_bytes(val, len); + hash_bytes(&bytes); + } + }, + ) }) }); // create