From 85a85c2070a6a967f1ccb1495391217fdb793112 Mon Sep 17 00:00:00 2001 From: Steven Fackler Date: Tue, 3 Feb 2015 23:15:52 -0800 Subject: Switch missing_copy_implementations to default-allow This was particularly helpful in the time just after OIBIT's implementation to make sure things that were supposed to be Copy continued to be, but it's now creates a lot of noise for types that intentionally don't want to be Copy. --- src/libstd/collections/hash/map.rs | 2 -- src/libstd/dynamic_lib.rs | 1 - src/libstd/os.rs | 1 - src/libstd/rand/os.rs | 1 - src/libstd/rt/unwind.rs | 3 --- src/libstd/rt/util.rs | 1 - src/libstd/sync/barrier.rs | 1 - src/libstd/sync/poison.rs | 1 - 8 files changed, 11 deletions(-) (limited to 'src/libstd') diff --git a/src/libstd/collections/hash/map.rs b/src/libstd/collections/hash/map.rs index 205eeb75b5b..81acd87a276 100644 --- a/src/libstd/collections/hash/map.rs +++ b/src/libstd/collections/hash/map.rs @@ -1580,7 +1580,6 @@ impl Extend<(K, V)> for HashMap /// `Hasher`, but the hashers created by two different `RandomState` /// instances are unlikely to produce the same result for the same values. #[derive(Clone)] -#[allow(missing_copy_implementations)] #[unstable(feature = "std_misc", reason = "hashing an hash maps may be altered")] pub struct RandomState { @@ -1622,7 +1621,6 @@ impl Default for RandomState { /// This is the default hasher used in a `HashMap` to hash keys. Types do not /// typically declare an ability to explicitly hash into this particular type, /// but rather in a `H: hash::Writer` type parameter. -#[allow(missing_copy_implementations)] #[unstable(feature = "std_misc", reason = "hashing an hash maps may be altered")] pub struct Hasher { inner: SipHasher } diff --git a/src/libstd/dynamic_lib.rs b/src/libstd/dynamic_lib.rs index 68ae0f7e5b5..51a88936034 100644 --- a/src/libstd/dynamic_lib.rs +++ b/src/libstd/dynamic_lib.rs @@ -22,7 +22,6 @@ use mem; use env; use str; -#[allow(missing_copy_implementations)] pub struct DynamicLibrary { handle: *mut u8 } diff --git a/src/libstd/os.rs b/src/libstd/os.rs index d92f361af0b..93dc8c49079 100644 --- a/src/libstd/os.rs +++ b/src/libstd/os.rs @@ -759,7 +759,6 @@ pub fn page_size() -> uint { /// /// The memory map is released (unmapped) when the destructor is run, so don't /// let it leave scope by accident if you want it to stick around. -#[allow(missing_copy_implementations)] pub struct MemoryMap { data: *mut u8, len: uint, diff --git a/src/libstd/rand/os.rs b/src/libstd/rand/os.rs index 4b45d5501c2..f24867d6d01 100644 --- a/src/libstd/rand/os.rs +++ b/src/libstd/rand/os.rs @@ -206,7 +206,6 @@ mod imp { /// - iOS: calls SecRandomCopyBytes as /dev/(u)random is sandboxed. /// /// This does not block. - #[allow(missing_copy_implementations)] pub struct OsRng { // dummy field to ensure that this struct cannot be constructed outside of this module _dummy: (), diff --git a/src/libstd/rt/unwind.rs b/src/libstd/rt/unwind.rs index 81ca5aa0e8a..b37996fa9d9 100644 --- a/src/libstd/rt/unwind.rs +++ b/src/libstd/rt/unwind.rs @@ -390,13 +390,10 @@ pub mod eabi { use libc::{c_void, c_int}; #[repr(C)] - #[allow(missing_copy_implementations)] pub struct EXCEPTION_RECORD; #[repr(C)] - #[allow(missing_copy_implementations)] pub struct CONTEXT; #[repr(C)] - #[allow(missing_copy_implementations)] pub struct DISPATCHER_CONTEXT; #[repr(C)] diff --git a/src/libstd/rt/util.rs b/src/libstd/rt/util.rs index 86d21cf7278..703dca4d29b 100644 --- a/src/libstd/rt/util.rs +++ b/src/libstd/rt/util.rs @@ -88,7 +88,6 @@ pub fn default_sched_threads() -> uint { pub const ENFORCE_SANITY: bool = true || !cfg!(rtopt) || cfg!(rtdebug) || cfg!(rtassert); -#[allow(missing_copy_implementations)] pub struct Stdio(libc::c_int); #[allow(non_upper_case_globals)] diff --git a/src/libstd/sync/barrier.rs b/src/libstd/sync/barrier.rs index 581e540d3b6..cca376f7b6d 100644 --- a/src/libstd/sync/barrier.rs +++ b/src/libstd/sync/barrier.rs @@ -46,7 +46,6 @@ struct BarrierState { /// /// Currently this opaque structure only has one method, `.is_leader()`. Only /// one thread will receive a result that will return `true` from this function. -#[allow(missing_copy_implementations)] pub struct BarrierWaitResult(bool); impl Barrier { diff --git a/src/libstd/sync/poison.rs b/src/libstd/sync/poison.rs index 18680b96592..d9bc37d312e 100644 --- a/src/libstd/sync/poison.rs +++ b/src/libstd/sync/poison.rs @@ -42,7 +42,6 @@ impl Flag { } } -#[allow(missing_copy_implementations)] pub struct Guard { panicking: bool, } -- cgit 1.4.1-3-g733a5