From 243f862617be1b72d35a21a71351e66adc911c8d Mon Sep 17 00:00:00 2001 From: str4d Date: Sat, 5 Jun 2021 13:18:14 +0100 Subject: [PATCH] Fix clippy lints Co-authored-by: Daira Hopwood --- src/constants.rs | 2 +- src/constants/load.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/constants.rs b/src/constants.rs index a628bdb23..72daeaa0e 100644 --- a/src/constants.rs +++ b/src/constants.rs @@ -237,7 +237,7 @@ fn test_zs_and_us(base: C, z: &[u64], u: &[[[u8; 32]; H]], num_w for ((u, z), window_points) in u.iter().zip(z.iter()).zip(window_table) { for (u, point) in u.iter().zip(window_points.iter()) { let y = *point.coordinates().unwrap().y(); - let u = C::Base::from_bytes(&u).unwrap(); + let u = C::Base::from_bytes(u).unwrap(); assert_eq!(C::Base::from_u64(*z) + y, u * u); // allow either square root assert!(bool::from((C::Base::from_u64(*z) - y).sqrt().is_none())); } diff --git a/src/constants/load.rs b/src/constants/load.rs index fe0eb3bc3..88a2c093c 100644 --- a/src/constants/load.rs +++ b/src/constants/load.rs @@ -171,7 +171,7 @@ impl From<&[[u8; 32]; H]> for WindowUs { Self( window_us .iter() - .map(|u| F::from_bytes(&u).unwrap()) + .map(|u| F::from_bytes(u).unwrap()) .collect::>() .into_boxed_slice() .try_into()