Skip to content

Commit

Permalink
Ensure that MSRV 1.76 works
Browse files Browse the repository at this point in the history
  • Loading branch information
aawsome committed Aug 11, 2024
1 parent 7cdb388 commit 3db5ace
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions crates/core/src/repofile/keyfile.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
// needed to ensuer Rust 1.76.0 works
#[allow(unused_imports)]
use std::mem::size_of;

use chrono::{DateTime, Local};
use rand::{thread_rng, RngCore};
use scrypt::Params;
Expand All @@ -18,7 +14,9 @@ use crate::{
pub(super) mod constants {
/// Returns the number of bits of the given type.
pub(super) const fn num_bits<T>() -> usize {
size_of::<T>() * 8
// Needed for MSRV 1.76
#![allow(unused_qualifications)]
std::mem::size_of::<T>() * 8
}
}

Expand Down

0 comments on commit 3db5ace

Please sign in to comment.