Skip to content
This repository was archived by the owner on Nov 30, 2022. It is now read-only.

Commit 8ded24c

Browse files
committed
Merge #143: Remove redundant slicing
d63557f Remove redundant slicing (Tobin Harding) Pull request description: Clippy emits: warning: redundant slicing of the whole range As suggested use `key` directly instead of the slice. ACKs for top commit: apoelstra: ACK d63557f Tree-SHA512: 4055f101b99b0f15ac856a0520107eac7d7ac320d9f893ac6f865c23ae44934639141efd9ffb7dc0d2e6a0898896edd800b989988313f614f7b52e2d834eb9a8
2 parents a3b2881 + d63557f commit 8ded24c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/hmac.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,10 @@ impl<T: HashTrait> HmacEngine<T> {
8585
*b_o ^= *b_h;
8686
}
8787
} else {
88-
for (b_i, b_h) in ipad.iter_mut().zip(&key[..]) {
88+
for (b_i, b_h) in ipad.iter_mut().zip(key) {
8989
*b_i ^= *b_h;
9090
}
91-
for (b_o, b_h) in opad.iter_mut().zip(&key[..]) {
91+
for (b_o, b_h) in opad.iter_mut().zip(key) {
9292
*b_o ^= *b_h;
9393
}
9494
};

0 commit comments

Comments
 (0)