diff options
| author | gnzlbg <gonzalobg88@gmail.com> | 2019-04-16 11:01:19 +0200 |
|---|---|---|
| committer | gnzlbg <gnzlbg@users.noreply.github.com> | 2019-04-17 14:20:42 +0200 |
| commit | 459afa7a592b6bc140836d0c426f854d63887c27 (patch) | |
| tree | 34c3c20a4162be535932ddffaccab53037171ce2 /library/stdarch/crates/std_detect/src/detect/cache.rs | |
| parent | eac0c6c8c1c4009fbc37bb54932e6240de005cb5 (diff) | |
| download | rust-459afa7a592b6bc140836d0c426f854d63887c27.tar.gz rust-459afa7a592b6bc140836d0c426f854d63887c27.zip | |
Fix clippy issues
Diffstat (limited to 'library/stdarch/crates/std_detect/src/detect/cache.rs')
| -rw-r--r-- | library/stdarch/crates/std_detect/src/detect/cache.rs | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/library/stdarch/crates/std_detect/src/detect/cache.rs b/library/stdarch/crates/std_detect/src/detect/cache.rs index 422bd6817da..92bc4b58d16 100644 --- a/library/stdarch/crates/std_detect/src/detect/cache.rs +++ b/library/stdarch/crates/std_detect/src/detect/cache.rs @@ -30,7 +30,7 @@ const CACHE_CAPACITY: u32 = 63; #[derive(Copy, Clone)] pub(crate) struct Initializer(u64); -#[cfg_attr(feature = "cargo-clippy", allow(clippy::use_self))] +#[allow(clippy::use_self)] impl Default for Initializer { fn default() -> Self { Initializer(0) @@ -76,13 +76,10 @@ static CACHE: Cache = Cache::uninitialized(); struct Cache(AtomicU64); #[cfg(target_pointer_width = "64")] -#[cfg_attr(feature = "cargo-clippy", allow(clippy::use_self))] +#[allow(clippy::use_self)] impl Cache { /// Creates an uninitialized cache. - #[cfg_attr( - feature = "cargo-clippy", - allow(clippy::declare_interior_mutable_const) - )] + #[allow(clippy::declare_interior_mutable_const)] const fn uninitialized() -> Self { Cache(AtomicU64::new(u64::max_value())) } |
