about summary refs log tree commit diff
path: root/library/stdarch/crates/std_detect/src/detect/cache.rs
diff options
context:
space:
mode:
authorgnzlbg <gonzalobg88@gmail.com>2019-02-05 08:22:18 +0100
committergnzlbg <gnzlbg@users.noreply.github.com>2019-02-05 09:34:34 +0100
commiteb13680d1aed60d8564f693aabb230ac189524e2 (patch)
treef321723c69b8efacb37a8a5c282c2c8759706028 /library/stdarch/crates/std_detect/src/detect/cache.rs
parente51ee17aa79ec4ccb2901ba128819bfccd5af651 (diff)
downloadrust-eb13680d1aed60d8564f693aabb230ac189524e2.tar.gz
rust-eb13680d1aed60d8564f693aabb230ac189524e2.zip
Remove const workaround in std_detect cache
Diffstat (limited to 'library/stdarch/crates/std_detect/src/detect/cache.rs')
-rw-r--r--library/stdarch/crates/std_detect/src/detect/cache.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/library/stdarch/crates/std_detect/src/detect/cache.rs b/library/stdarch/crates/std_detect/src/detect/cache.rs
index 944dccbe6df..1ab94dd1cd9 100644
--- a/library/stdarch/crates/std_detect/src/detect/cache.rs
+++ b/library/stdarch/crates/std_detect/src/detect/cache.rs
@@ -84,8 +84,7 @@ impl Cache {
         allow(clippy::declare_interior_mutable_const)
     )]
     const fn uninitialized() -> Self {
-        const X: AtomicU64 = AtomicU64::new(u64::max_value());
-        Cache(X)
+        Cache(AtomicU64::new(u64::max_value()))
     }
     /// Is the cache uninitialized?
     #[inline]