diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2014-08-05 16:40:04 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2014-08-07 08:54:38 -0700 |
| commit | 1f760d5d1a448c08ff4b66cfa8d35d39a5d667c0 (patch) | |
| tree | 9befa0d5628cafad50e44dbc28e494dbf3b45487 /src/libsync/deque.rs | |
| parent | b09a02b41588b2348fcce89c37c4a2cdc614d350 (diff) | |
Rename `Share` to `Sync`
This leaves the `Share` trait at `std::kinds` via a `#[deprecated]` `pub use` statement, but the `NoShare` struct is no longer part of `std::kinds::marker` due to #12660 (the build cannot bootstrap otherwise). All code referencing the `Share` trait should now reference the `Sync` trait, and all code referencing the `NoShare` type should now reference the `NoSync` type. The functionality and meaning of this trait have not changed, only the naming. Closes #16281 [breaking-change]
Diffstat (limited to 'src/libsync/deque.rs')
| -rw-r--r-- | src/libsync/deque.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libsync/deque.rs b/src/libsync/deque.rs index d5a05e7a681..e70a730dc3a 100644 --- a/src/libsync/deque.rs +++ b/src/libsync/deque.rs @@ -87,7 +87,7 @@ struct Deque<T> { /// There may only be one worker per deque. pub struct Worker<T> { deque: Arc<Deque<T>>, - noshare: marker::NoShare, + noshare: marker::NoSync, } /// The stealing half of the work-stealing deque. Stealers have access to the @@ -95,7 +95,7 @@ pub struct Worker<T> { /// `steal` method. pub struct Stealer<T> { deque: Arc<Deque<T>>, - noshare: marker::NoShare, + noshare: marker::NoSync, } /// When stealing some data, this is an enumeration of the possible outcomes. @@ -153,8 +153,8 @@ impl<T: Send> BufferPool<T> { pub fn deque(&self) -> (Worker<T>, Stealer<T>) { let a = Arc::new(Deque::new(self.clone())); let b = a.clone(); - (Worker { deque: a, noshare: marker::NoShare }, - Stealer { deque: b, noshare: marker::NoShare }) + (Worker { deque: a, noshare: marker::NoSync }, + Stealer { deque: b, noshare: marker::NoSync }) } fn alloc(&mut self, bits: uint) -> Box<Buffer<T>> { @@ -217,7 +217,7 @@ impl<T: Send> Stealer<T> { impl<T: Send> Clone for Stealer<T> { fn clone(&self) -> Stealer<T> { - Stealer { deque: self.deque.clone(), noshare: marker::NoShare } + Stealer { deque: self.deque.clone(), noshare: marker::NoSync } } } |
