diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2015-01-02 09:19:00 -0800 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2015-01-02 09:19:00 -0800 |
| commit | 009ec5d2b0c4ab0e7dc7ab2f6b15754b4da14caf (patch) | |
| tree | 8b441fd58860857f2e7bf5eabbf2226b92bf13c7 /src/libcore | |
| parent | 0101bbe7acb38e8113c0cafeb7d5ae0be6448e5b (diff) | |
| parent | f3a7ec7028c76b3a1c6051131328f372b068e33a (diff) | |
| download | rust-009ec5d2b0c4ab0e7dc7ab2f6b15754b4da14caf.tar.gz rust-009ec5d2b0c4ab0e7dc7ab2f6b15754b4da14caf.zip | |
rollup merge of #20315: alexcrichton/std-sync
Conflicts: src/libstd/rt/exclusive.rs src/libstd/sync/barrier.rs src/libstd/sys/unix/pipe.rs src/test/bench/shootout-binarytrees.rs src/test/bench/shootout-fannkuch-redux.rs
Diffstat (limited to 'src/libcore')
| -rw-r--r-- | src/libcore/atomic.rs | 16 | ||||
| -rw-r--r-- | src/libcore/cell.rs | 2 |
2 files changed, 15 insertions, 3 deletions
diff --git a/src/libcore/atomic.rs b/src/libcore/atomic.rs index 6a40915f4dd..f653998c9bf 100644 --- a/src/libcore/atomic.rs +++ b/src/libcore/atomic.rs @@ -89,17 +89,27 @@ pub enum Ordering { /// An `AtomicBool` initialized to `false`. #[unstable = "may be renamed, pending conventions for static initalizers"] -pub const INIT_ATOMIC_BOOL: AtomicBool = +pub const ATOMIC_BOOL_INIT: AtomicBool = AtomicBool { v: UnsafeCell { value: 0 } }; /// An `AtomicInt` initialized to `0`. #[unstable = "may be renamed, pending conventions for static initalizers"] -pub const INIT_ATOMIC_INT: AtomicInt = +pub const ATOMIC_INT_INIT: AtomicInt = AtomicInt { v: UnsafeCell { value: 0 } }; /// An `AtomicUint` initialized to `0`. #[unstable = "may be renamed, pending conventions for static initalizers"] -pub const INIT_ATOMIC_UINT: AtomicUint = +pub const ATOMIC_UINT_INIT: AtomicUint = AtomicUint { v: UnsafeCell { value: 0, } }; +/// Deprecated +#[deprecated = "renamed to ATOMIC_BOOL_INIT"] +pub const INIT_ATOMIC_BOOL: AtomicBool = ATOMIC_BOOL_INIT; +/// Deprecated +#[deprecated = "renamed to ATOMIC_INT_INIT"] +pub const INIT_ATOMIC_INT: AtomicInt = ATOMIC_INT_INIT; +/// Deprecated +#[deprecated = "renamed to ATOMIC_UINT_INIT"] +pub const INIT_ATOMIC_UINT: AtomicUint = ATOMIC_UINT_INIT; + // NB: Needs to be -1 (0b11111111...) to make fetch_nand work correctly const UINT_TRUE: uint = -1; diff --git a/src/libcore/cell.rs b/src/libcore/cell.rs index 4b246860006..94e9441abc8 100644 --- a/src/libcore/cell.rs +++ b/src/libcore/cell.rs @@ -155,6 +155,8 @@ // FIXME: Can't be shared between threads. Dynamic borrows // FIXME: Relationship to Atomic types and RWLock +#![stable] + use clone::Clone; use cmp::PartialEq; use default::Default; |
