Skip to content

Commit 92b4e9b

Browse files
authored
CI: bump clippy to 1.84 (#550)
Also runs `cargo clippy --fix`
1 parent eeefe4b commit 92b4e9b

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

.github/workflows/workspace.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
- uses: RustCrypto/actions/cargo-cache@master
1818
- uses: dtolnay/rust-toolchain@master
1919
with:
20-
toolchain: 1.81.0
20+
toolchain: 1.84.0
2121
components: clippy
2222
- run: cargo clippy --all -- -D warnings
2323

argon2/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -635,13 +635,13 @@ impl PasswordHasher for Argon2<'_> {
635635
}
636636
}
637637

638-
impl<'key> From<Params> for Argon2<'key> {
638+
impl From<Params> for Argon2<'_> {
639639
fn from(params: Params) -> Self {
640640
Self::new(Algorithm::default(), Version::default(), params)
641641
}
642642
}
643643

644-
impl<'key> From<&Params> for Argon2<'key> {
644+
impl From<&Params> for Argon2<'_> {
645645
fn from(params: &Params) -> Self {
646646
Self::from(params.clone())
647647
}

balloon-hash/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ where
269269
}
270270
}
271271

272-
impl<'key, D: Digest + FixedOutputReset> From<Params> for Balloon<'key, D>
272+
impl<D: Digest + FixedOutputReset> From<Params> for Balloon<'_, D>
273273
where
274274
Array<u8, D::OutputSize>: ArrayDecoding,
275275
{

bcrypt-pbkdf/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ pub fn bcrypt_pbkdf(
135135
const STACK_STRIDE: usize = 8;
136136

137137
// Allocate a Vec large enough to hold the output we require.
138-
let stride = (output.len() + BHASH_OUTPUT_SIZE - 1) / BHASH_OUTPUT_SIZE;
138+
let stride = output.len().div_ceil(BHASH_OUTPUT_SIZE);
139139

140140
let mut vec_buf;
141141
let mut stack_buf = [0u8; STACK_STRIDE * BHASH_OUTPUT_SIZE];
@@ -172,7 +172,7 @@ pub fn bcrypt_pbkdf_with_memory(
172172
output: &mut [u8],
173173
memory: &mut [u8],
174174
) -> Result<(), Error> {
175-
let stride = (output.len() + BHASH_OUTPUT_SIZE - 1) / BHASH_OUTPUT_SIZE;
175+
let stride = output.len().div_ceil(BHASH_OUTPUT_SIZE);
176176

177177
// Validate inputs in same way as OpenSSH implementation
178178
let passphrase = passphrase.as_ref();

0 commit comments

Comments
 (0)