diff --git a/hashes/src/ripemd160.rs b/hashes/src/ripemd160.rs index 30d24172..4b750978 100644 --- a/hashes/src/ripemd160.rs +++ b/hashes/src/ripemd160.rs @@ -469,7 +469,7 @@ mod tests { for test in tests { // Hash through high-level API, check hex encoding/decoding - let hash = ripemd160::Hash::hash(&test.input.as_bytes()); + let hash = ripemd160::Hash::hash(test.input.as_bytes()); assert_eq!(hash, ripemd160::Hash::from_hex(test.output_str).expect("parse hex")); assert_eq!(&hash[..], &test.output[..]); assert_eq!(&hash.to_hex(), &test.output_str); diff --git a/hashes/src/sha1.rs b/hashes/src/sha1.rs index a342d193..f5cae9a2 100644 --- a/hashes/src/sha1.rs +++ b/hashes/src/sha1.rs @@ -195,7 +195,7 @@ mod tests { for test in tests { // Hash through high-level API, check hex encoding/decoding - let hash = sha1::Hash::hash(&test.input.as_bytes()); + let hash = sha1::Hash::hash(test.input.as_bytes()); assert_eq!(hash, sha1::Hash::from_hex(test.output_str).expect("parse hex")); assert_eq!(&hash[..], &test.output[..]); assert_eq!(&hash.to_hex(), &test.output_str); diff --git a/hashes/src/sha256.rs b/hashes/src/sha256.rs index cc4d5364..b6336fa6 100644 --- a/hashes/src/sha256.rs +++ b/hashes/src/sha256.rs @@ -371,7 +371,7 @@ mod tests { for test in tests { // Hash through high-level API, check hex encoding/decoding - let hash = sha256::Hash::hash(&test.input.as_bytes()); + let hash = sha256::Hash::hash(test.input.as_bytes()); assert_eq!(hash, sha256::Hash::from_hex(test.output_str).expect("parse hex")); assert_eq!(&hash[..], &test.output[..]); assert_eq!(&hash.to_hex(), &test.output_str); diff --git a/hashes/src/sha256d.rs b/hashes/src/sha256d.rs index 6ecccdc4..1a3e75b3 100644 --- a/hashes/src/sha256d.rs +++ b/hashes/src/sha256d.rs @@ -74,7 +74,7 @@ mod tests { for test in tests { // Hash through high-level API, check hex encoding/decoding - let hash = sha256d::Hash::hash(&test.input.as_bytes()); + let hash = sha256d::Hash::hash(test.input.as_bytes()); assert_eq!(hash, sha256d::Hash::from_hex(test.output_str).expect("parse hex")); assert_eq!(&hash[..], &test.output[..]); assert_eq!(&hash.to_hex(), &test.output_str); diff --git a/hashes/src/sha512.rs b/hashes/src/sha512.rs index 3298d4a6..876614a0 100644 --- a/hashes/src/sha512.rs +++ b/hashes/src/sha512.rs @@ -368,7 +368,7 @@ mod tests { for test in tests { // Hash through high-level API, check hex encoding/decoding - let hash = sha512::Hash::hash(&test.input.as_bytes()); + let hash = sha512::Hash::hash(test.input.as_bytes()); assert_eq!(hash, sha512::Hash::from_hex(test.output_str).expect("parse hex")); assert_eq!(&hash[..], &test.output[..]); assert_eq!(&hash.to_hex(), &test.output_str);