diff options
| author | pravic <[email protected]> | 2016-04-29 21:16:15 +0300 |
|---|---|---|
| committer | pravic <[email protected]> | 2016-04-29 21:16:15 +0300 |
| commit | 77e9a3167b4aaadf3583a0c1d1ee0d9e63c9a000 (patch) | |
| tree | 710e445d56a1a582b8eff19b7b4b180276eae122 /libcore/sync/atomic.rs | |
| parent | tweak: /driver option specifies /fixed:no implicitly as well (diff) | |
| download | kmd-env-rs-77e9a3167b4aaadf3583a0c1d1ee0d9e63c9a000.tar.xz kmd-env-rs-77e9a3167b4aaadf3583a0c1d1ee0d9e63c9a000.zip | |
update libcore to 2016-04-29 nightly
Diffstat (limited to 'libcore/sync/atomic.rs')
| -rw-r--r-- | libcore/sync/atomic.rs | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/libcore/sync/atomic.rs b/libcore/sync/atomic.rs index 483c382..e74dc08 100644 --- a/libcore/sync/atomic.rs +++ b/libcore/sync/atomic.rs @@ -1380,7 +1380,6 @@ unsafe fn atomic_sub<T>(dst: *mut T, val: T, order: Ordering) -> T { } #[inline] -#[cfg(any(not(stage0), cargobuild))] unsafe fn atomic_compare_exchange<T>(dst: *mut T, old: T, new: T, @@ -1408,29 +1407,6 @@ unsafe fn atomic_compare_exchange<T>(dst: *mut T, } #[inline] -#[cfg(all(stage0, not(cargobuild)))] -unsafe fn atomic_compare_exchange<T>(dst: *mut T, - old: T, - new: T, - success: Ordering, - _: Ordering) -> Result<T, T> - where T: ::cmp::Eq + ::marker::Copy -{ - let val = match success { - Acquire => intrinsics::atomic_cxchg_acq(dst, old, new), - Release => intrinsics::atomic_cxchg_rel(dst, old, new), - AcqRel => intrinsics::atomic_cxchg_acqrel(dst, old, new), - Relaxed => intrinsics::atomic_cxchg_relaxed(dst, old, new), - SeqCst => intrinsics::atomic_cxchg(dst, old, new), - }; - if val == old { - Ok(val) - } else { - Err(val) - } -} - -#[inline] unsafe fn atomic_compare_exchange_weak<T>(dst: *mut T, old: T, new: T, |