From cd631c6914d384538352604059a7e4abb31d8c46 Mon Sep 17 00:00:00 2001 From: Flavio Percoco Date: Tue, 20 Jan 2015 15:51:09 +0100 Subject: Register snapshot for 9006c3c --- src/libstd/sync/mutex.rs | 32 -------------------------------- 1 file changed, 32 deletions(-) (limited to 'src/libstd/sync/mutex.rs') diff --git a/src/libstd/sync/mutex.rs b/src/libstd/sync/mutex.rs index 73d5332d16f..6ddfe3e075b 100644 --- a/src/libstd/sync/mutex.rs +++ b/src/libstd/sync/mutex.rs @@ -160,33 +160,14 @@ unsafe impl Sync for StaticMutex {} /// Deref and DerefMut implementations #[must_use] #[stable] -#[cfg(stage0)] // NOTE remove impl after next snapshot pub struct MutexGuard<'a, T: 'a> { // funny underscores due to how Deref/DerefMut currently work (they // disregard field privacy). __lock: &'a StaticMutex, __data: &'a UnsafeCell, __poison: poison::Guard, - __marker: marker::NoSend, } -/// An RAII implementation of a "scoped lock" of a mutex. When this structure is -/// dropped (falls out of scope), the lock will be unlocked. -/// -/// The data protected by the mutex can be access through this guard via its -/// Deref and DerefMut implementations -#[must_use] -#[stable] -#[cfg(not(stage0))] // NOTE remove cfg after next snapshot -pub struct MutexGuard<'a, T: 'a> { - // funny underscores due to how Deref/DerefMut currently work (they - // disregard field privacy). - __lock: &'a StaticMutex, - __data: &'a UnsafeCell, - __poison: poison::Guard, -} - -#[cfg(not(stage0))] // NOTE remove cfg after next snapshot impl<'a, T> !marker::Send for MutexGuard<'a, T> {} /// Static initialization of a mutex. This constant can be used to initialize @@ -299,20 +280,7 @@ impl StaticMutex { } impl<'mutex, T> MutexGuard<'mutex, T> { - #[cfg(stage0)] // NOTE remove afte next snapshot - fn new(lock: &'mutex StaticMutex, data: &'mutex UnsafeCell) - -> LockResult> { - poison::map_result(lock.poison.borrow(), |guard| { - MutexGuard { - __lock: lock, - __data: data, - __poison: guard, - __marker: marker::NoSend, - } - }) - } - #[cfg(not(stage0))] // NOTE remove cfg afte next snapshot fn new(lock: &'mutex StaticMutex, data: &'mutex UnsafeCell) -> LockResult> { poison::map_result(lock.poison.borrow(), |guard| { -- cgit 1.4.1-3-g733a5