diff options
| author | Brian Anderson <banderson@mozilla.com> | 2015-01-23 21:48:20 -0800 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2015-01-23 21:48:20 -0800 |
| commit | b44ee371b8beea77aa1364460acbba14a8516559 (patch) | |
| tree | 92f5140fe5a2e5e364a4298651bf3c6bdf0f0940 /src/libstd | |
| parent | b7fe2c54b7d638e38fcbe3284ff6295f2df6c928 (diff) | |
| download | rust-b44ee371b8beea77aa1364460acbba14a8516559.tar.gz rust-b44ee371b8beea77aa1364460acbba14a8516559.zip | |
grandfathered -> rust1
Diffstat (limited to 'src/libstd')
38 files changed, 280 insertions, 280 deletions
diff --git a/src/libstd/bool.rs b/src/libstd/bool.rs index 6ec1299aac5..0d8b233a169 100644 --- a/src/libstd/bool.rs +++ b/src/libstd/bool.rs @@ -11,5 +11,5 @@ //! The boolean type #![doc(primitive = "bool")] -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] diff --git a/src/libstd/collections/hash/map.rs b/src/libstd/collections/hash/map.rs index 0a0aaa9da87..4ce9639bedb 100644 --- a/src/libstd/collections/hash/map.rs +++ b/src/libstd/collections/hash/map.rs @@ -296,7 +296,7 @@ fn test_resize_policy() { /// } /// ``` #[derive(Clone)] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct HashMap<K, V, S = RandomState> { // All hashes are keyed on these values, to prevent hash collision attacks. hash_state: S, @@ -499,7 +499,7 @@ impl<K: Hash<Hasher> + Eq, V> HashMap<K, V, RandomState> { /// let mut map: HashMap<&str, int> = HashMap::new(); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn new() -> HashMap<K, V, RandomState> { Default::default() } @@ -513,7 +513,7 @@ impl<K: Hash<Hasher> + Eq, V> HashMap<K, V, RandomState> { /// let mut map: HashMap<&str, int> = HashMap::with_capacity(10); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn with_capacity(capacity: uint) -> HashMap<K, V, RandomState> { HashMap::with_capacity_and_hash_state(capacity, Default::default()) } @@ -591,7 +591,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// assert!(map.capacity() >= 100); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn capacity(&self) -> uint { self.resize_policy.usable_capacity(self.table.capacity()) } @@ -611,7 +611,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// let mut map: HashMap<&str, int> = HashMap::new(); /// map.reserve(10); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn reserve(&mut self, additional: uint) { let new_size = self.len().checked_add(additional).expect("capacity overflow"); let min_cap = self.resize_policy.min_capacity(new_size); @@ -723,7 +723,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// map.shrink_to_fit(); /// assert!(map.capacity() >= 2); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn shrink_to_fit(&mut self) { let min_capacity = self.resize_policy.min_capacity(self.len()); let min_capacity = max(min_capacity.next_power_of_two(), INITIAL_CAPACITY); @@ -817,7 +817,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// println!("{}", key); /// } /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn keys<'a>(&'a self) -> Keys<'a, K, V> { fn first<A, B>((a, _): (A, B)) -> A { a } let first: fn((&'a K,&'a V)) -> &'a K = first; // coerce to fn ptr @@ -842,7 +842,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// println!("{}", key); /// } /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn values<'a>(&'a self) -> Values<'a, K, V> { fn second<A, B>((_, b): (A, B)) -> B { b } let second: fn((&'a K,&'a V)) -> &'a V = second; // coerce to fn ptr @@ -867,7 +867,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// println!("key: {} val: {}", key, val); /// } /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn iter(&self) -> Iter<K, V> { Iter { inner: self.table.iter() } } @@ -895,7 +895,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// println!("key: {} val: {}", key, val); /// } /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn iter_mut(&mut self) -> IterMut<K, V> { IterMut { inner: self.table.iter_mut() } } @@ -917,7 +917,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// // Not possible with .iter() /// let vec: Vec<(&str, int)> = map.into_iter().collect(); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn into_iter(self) -> IntoIter<K, V> { fn last_two<A, B, C>((_, b, c): (A, B, C)) -> (B, C) { (b, c) } let last_two: fn((SafeHash, K, V)) -> (K, V) = last_two; @@ -951,7 +951,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// a.insert(1u, "a"); /// assert_eq!(a.len(), 1); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn len(&self) -> uint { self.table.size() } /// Return true if the map contains no elements. @@ -967,7 +967,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// assert!(!a.is_empty()); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn is_empty(&self) -> bool { self.len() == 0 } /// Clears the map, returning all key-value pairs as an iterator. Keeps the @@ -1014,7 +1014,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// a.clear(); /// assert!(a.is_empty()); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] #[inline] pub fn clear(&mut self) { self.drain(); @@ -1036,7 +1036,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// assert_eq!(map.get(&1), Some(&"a")); /// assert_eq!(map.get(&2), None); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn get<Q: ?Sized>(&self, k: &Q) -> Option<&V> where Q: Hash<H> + Eq + BorrowFrom<K> { @@ -1059,7 +1059,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// assert_eq!(map.contains_key(&1), true); /// assert_eq!(map.contains_key(&2), false); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn contains_key<Q: ?Sized>(&self, k: &Q) -> bool where Q: Hash<H> + Eq + BorrowFrom<K> { @@ -1085,7 +1085,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// } /// assert_eq!(map[1], "b"); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn get_mut<Q: ?Sized>(&mut self, k: &Q) -> Option<&mut V> where Q: Hash<H> + Eq + BorrowFrom<K> { @@ -1108,7 +1108,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// assert_eq!(map.insert(37, "c"), Some("b")); /// assert_eq!(map[37], "c"); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn insert(&mut self, k: K, v: V) -> Option<V> { let hash = self.make_hash(&k); self.reserve(1); @@ -1137,7 +1137,7 @@ impl<K, V, S, H> HashMap<K, V, S> /// assert_eq!(map.remove(&1), Some("a")); /// assert_eq!(map.remove(&1), None); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn remove<Q: ?Sized>(&mut self, k: &Q) -> Option<V> where Q: Hash<H> + Eq + BorrowFrom<K> { @@ -1210,14 +1210,14 @@ impl<K, V, S, H> PartialEq for HashMap<K, V, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V, S, H> Eq for HashMap<K, V, S> where K: Eq + Hash<H>, V: Eq, S: HashState<Hasher=H>, H: hash::Hasher<Output=u64> {} -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V, S, H> Show for HashMap<K, V, S> where K: Eq + Hash<H> + Show, V: Show, S: HashState<Hasher=H>, @@ -1235,7 +1235,7 @@ impl<K, V, S, H> Show for HashMap<K, V, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V, S, H> Default for HashMap<K, V, S> where K: Eq + Hash<H>, S: HashState<Hasher=H> + Default, @@ -1246,7 +1246,7 @@ impl<K, V, S, H> Default for HashMap<K, V, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, Q: ?Sized, V, S, H> Index<Q> for HashMap<K, V, S> where K: Eq + Hash<H>, Q: Eq + Hash<H> + BorrowFrom<K>, @@ -1261,7 +1261,7 @@ impl<K, Q: ?Sized, V, S, H> Index<Q> for HashMap<K, V, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V, S, H, Q: ?Sized> IndexMut<Q> for HashMap<K, V, S> where K: Eq + Hash<H>, Q: Eq + Hash<H> + BorrowFrom<K>, @@ -1277,7 +1277,7 @@ impl<K, V, S, H, Q: ?Sized> IndexMut<Q> for HashMap<K, V, S> } /// HashMap iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Iter<'a, K: 'a, V: 'a> { inner: table::Iter<'a, K, V> } @@ -1292,13 +1292,13 @@ impl<'a, K, V> Clone for Iter<'a, K, V> { } /// HashMap mutable values iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct IterMut<'a, K: 'a, V: 'a> { inner: table::IterMut<'a, K, V> } /// HashMap move iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct IntoIter<K, V> { inner: iter::Map< (SafeHash, K, V), @@ -1309,7 +1309,7 @@ pub struct IntoIter<K, V> { } /// HashMap keys iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Keys<'a, K: 'a, V: 'a> { inner: Map<(&'a K, &'a V), &'a K, Iter<'a, K, V>, fn((&'a K, &'a V)) -> &'a K> } @@ -1324,7 +1324,7 @@ impl<'a, K, V> Clone for Keys<'a, K, V> { } /// HashMap values iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Values<'a, K: 'a, V: 'a> { inner: Map<(&'a K, &'a V), &'a V, Iter<'a, K, V>, fn((&'a K, &'a V)) -> &'a V> } @@ -1385,74 +1385,74 @@ enum VacantEntryState<K, V, M> { NoElem(EmptyBucket<K, V, M>), } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> Iterator for Iter<'a, K, V> { type Item = (&'a K, &'a V); #[inline] fn next(&mut self) -> Option<(&'a K, &'a V)> { self.inner.next() } #[inline] fn size_hint(&self) -> (usize, Option<usize>) { self.inner.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> ExactSizeIterator for Iter<'a, K, V> { #[inline] fn len(&self) -> usize { self.inner.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> Iterator for IterMut<'a, K, V> { type Item = (&'a K, &'a mut V); #[inline] fn next(&mut self) -> Option<(&'a K, &'a mut V)> { self.inner.next() } #[inline] fn size_hint(&self) -> (usize, Option<usize>) { self.inner.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> ExactSizeIterator for IterMut<'a, K, V> { #[inline] fn len(&self) -> usize { self.inner.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V> Iterator for IntoIter<K, V> { type Item = (K, V); #[inline] fn next(&mut self) -> Option<(K, V)> { self.inner.next() } #[inline] fn size_hint(&self) -> (usize, Option<usize>) { self.inner.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V> ExactSizeIterator for IntoIter<K, V> { #[inline] fn len(&self) -> usize { self.inner.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> Iterator for Keys<'a, K, V> { type Item = &'a K; #[inline] fn next(&mut self) -> Option<(&'a K)> { self.inner.next() } #[inline] fn size_hint(&self) -> (usize, Option<usize>) { self.inner.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> ExactSizeIterator for Keys<'a, K, V> { #[inline] fn len(&self) -> usize { self.inner.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> Iterator for Values<'a, K, V> { type Item = &'a V; #[inline] fn next(&mut self) -> Option<(&'a V)> { self.inner.next() } #[inline] fn size_hint(&self) -> (usize, Option<usize>) { self.inner.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> ExactSizeIterator for Values<'a, K, V> { #[inline] fn len(&self) -> usize { self.inner.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> Iterator for Drain<'a, K, V> { type Item = (K, V); #[inline] fn next(&mut self) -> Option<(K, V)> { self.inner.next() } #[inline] fn size_hint(&self) -> (usize, Option<usize>) { self.inner.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K, V> ExactSizeIterator for Drain<'a, K, V> { #[inline] fn len(&self) -> usize { self.inner.len() } } @@ -1518,7 +1518,7 @@ impl<'a, K: 'a, V: 'a> VacantEntry<'a, K, V> { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V, S, H> FromIterator<(K, V)> for HashMap<K, V, S> where K: Eq + Hash<H>, S: HashState<Hasher=H> + Default, @@ -1533,7 +1533,7 @@ impl<K, V, S, H> FromIterator<(K, V)> for HashMap<K, V, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K, V, S, H> Extend<(K, V)> for HashMap<K, V, S> where K: Eq + Hash<H>, S: HashState<Hasher=H>, diff --git a/src/libstd/collections/hash/set.rs b/src/libstd/collections/hash/set.rs index 98c67186a3c..a6ebc402ade 100644 --- a/src/libstd/collections/hash/set.rs +++ b/src/libstd/collections/hash/set.rs @@ -90,7 +90,7 @@ use super::state::HashState; /// } /// ``` #[derive(Clone)] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct HashSet<T, S = RandomState> { map: HashMap<T, (), S> } @@ -105,7 +105,7 @@ impl<T: Hash<Hasher> + Eq> HashSet<T, RandomState> { /// let mut set: HashSet<int> = HashSet::new(); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn new() -> HashSet<T, RandomState> { HashSet::with_capacity(INITIAL_CAPACITY) } @@ -120,7 +120,7 @@ impl<T: Hash<Hasher> + Eq> HashSet<T, RandomState> { /// let mut set: HashSet<int> = HashSet::with_capacity(10); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn with_capacity(capacity: uint) -> HashSet<T, RandomState> { HashSet { map: HashMap::with_capacity(capacity) } } @@ -189,7 +189,7 @@ impl<T, S, H> HashSet<T, S> /// assert!(set.capacity() >= 100); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn capacity(&self) -> uint { self.map.capacity() } @@ -209,7 +209,7 @@ impl<T, S, H> HashSet<T, S> /// let mut set: HashSet<int> = HashSet::new(); /// set.reserve(10); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn reserve(&mut self, additional: uint) { self.map.reserve(additional) } @@ -230,7 +230,7 @@ impl<T, S, H> HashSet<T, S> /// set.shrink_to_fit(); /// assert!(set.capacity() >= 2); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn shrink_to_fit(&mut self) { self.map.shrink_to_fit() } @@ -251,7 +251,7 @@ impl<T, S, H> HashSet<T, S> /// println!("{}", x); /// } /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn iter(&self) -> Iter<T> { Iter { iter: self.map.keys() } } @@ -276,7 +276,7 @@ impl<T, S, H> HashSet<T, S> /// println!("{}", x); /// } /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn into_iter(self) -> IntoIter<T> { fn first<A, B>((a, _): (A, B)) -> A { a } let first: fn((T, ())) -> T = first; @@ -306,7 +306,7 @@ impl<T, S, H> HashSet<T, S> /// let diff: HashSet<int> = b.difference(&a).map(|&x| x).collect(); /// assert_eq!(diff, [4i].iter().map(|&x| x).collect()); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn difference<'a>(&'a self, other: &'a HashSet<T, S>) -> Difference<'a, T, S> { Difference { iter: self.iter(), @@ -334,7 +334,7 @@ impl<T, S, H> HashSet<T, S> /// assert_eq!(diff1, diff2); /// assert_eq!(diff1, [1i, 4].iter().map(|&x| x).collect()); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn symmetric_difference<'a>(&'a self, other: &'a HashSet<T, S>) -> SymmetricDifference<'a, T, S> { SymmetricDifference { iter: self.difference(other).chain(other.difference(self)) } @@ -357,7 +357,7 @@ impl<T, S, H> HashSet<T, S> /// let diff: HashSet<int> = a.intersection(&b).map(|&x| x).collect(); /// assert_eq!(diff, [2i, 3].iter().map(|&x| x).collect()); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn intersection<'a>(&'a self, other: &'a HashSet<T, S>) -> Intersection<'a, T, S> { Intersection { iter: self.iter(), @@ -382,7 +382,7 @@ impl<T, S, H> HashSet<T, S> /// let diff: HashSet<int> = a.union(&b).map(|&x| x).collect(); /// assert_eq!(diff, [1i, 2, 3, 4].iter().map(|&x| x).collect()); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn union<'a>(&'a self, other: &'a HashSet<T, S>) -> Union<'a, T, S> { Union { iter: self.iter().chain(other.difference(self)) } } @@ -399,7 +399,7 @@ impl<T, S, H> HashSet<T, S> /// v.insert(1u); /// assert_eq!(v.len(), 1); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn len(&self) -> uint { self.map.len() } /// Returns true if the set contains no elements @@ -414,7 +414,7 @@ impl<T, S, H> HashSet<T, S> /// v.insert(1u); /// assert!(!v.is_empty()); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn is_empty(&self) -> bool { self.map.len() == 0 } /// Clears the set, returning all elements in an iterator. @@ -440,7 +440,7 @@ impl<T, S, H> HashSet<T, S> /// v.clear(); /// assert!(v.is_empty()); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn clear(&mut self) { self.map.clear() } /// Returns `true` if the set contains a value. @@ -458,7 +458,7 @@ impl<T, S, H> HashSet<T, S> /// assert_eq!(set.contains(&1), true); /// assert_eq!(set.contains(&4), false); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn contains<Q: ?Sized>(&self, value: &Q) -> bool where Q: BorrowFrom<T> + Hash<H> + Eq { @@ -482,7 +482,7 @@ impl<T, S, H> HashSet<T, S> /// b.insert(1); /// assert_eq!(a.is_disjoint(&b), false); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn is_disjoint(&self, other: &HashSet<T, S>) -> bool { self.iter().all(|v| !other.contains(v)) } @@ -503,7 +503,7 @@ impl<T, S, H> HashSet<T, S> /// set.insert(4); /// assert_eq!(set.is_subset(&sup), false); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn is_subset(&self, other: &HashSet<T, S>) -> bool { self.iter().all(|v| other.contains(v)) } @@ -528,7 +528,7 @@ impl<T, S, H> HashSet<T, S> /// assert_eq!(set.is_superset(&sub), true); /// ``` #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn is_superset(&self, other: &HashSet<T, S>) -> bool { other.is_subset(self) } @@ -547,7 +547,7 @@ impl<T, S, H> HashSet<T, S> /// assert_eq!(set.insert(2), false); /// assert_eq!(set.len(), 1); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn insert(&mut self, value: T) -> bool { self.map.insert(value, ()).is_none() } /// Removes a value from the set. Returns `true` if the value was @@ -568,7 +568,7 @@ impl<T, S, H> HashSet<T, S> /// assert_eq!(set.remove(&2), true); /// assert_eq!(set.remove(&2), false); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn remove<Q: ?Sized>(&mut self, value: &Q) -> bool where Q: BorrowFrom<T> + Hash<H> + Eq { @@ -576,7 +576,7 @@ impl<T, S, H> HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T, S, H> PartialEq for HashSet<T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H>, @@ -589,14 +589,14 @@ impl<T, S, H> PartialEq for HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T, S, H> Eq for HashSet<T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H>, H: hash::Hasher<Output=u64> {} -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T, S, H> fmt::Show for HashSet<T, S> where T: Eq + Hash<H> + fmt::Show, S: HashState<Hasher=H>, @@ -614,7 +614,7 @@ impl<T, S, H> fmt::Show for HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T, S, H> FromIterator<T> for HashSet<T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H> + Default, @@ -628,7 +628,7 @@ impl<T, S, H> FromIterator<T> for HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T, S, H> Extend<T> for HashSet<T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H>, @@ -641,19 +641,19 @@ impl<T, S, H> Extend<T> for HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T, S, H> Default for HashSet<T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H> + Default, H: hash::Hasher<Output=u64> { - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn default() -> HashSet<T, S> { HashSet::with_hash_state(Default::default()) } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, 'b, T, S, H> BitOr<&'b HashSet<T, S>> for &'a HashSet<T, S> where T: Eq + Hash<H> + Clone, S: HashState<Hasher=H> + Default, @@ -686,7 +686,7 @@ impl<'a, 'b, T, S, H> BitOr<&'b HashSet<T, S>> for &'a HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, 'b, T, S, H> BitAnd<&'b HashSet<T, S>> for &'a HashSet<T, S> where T: Eq + Hash<H> + Clone, S: HashState<Hasher=H> + Default, @@ -719,7 +719,7 @@ impl<'a, 'b, T, S, H> BitAnd<&'b HashSet<T, S>> for &'a HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, 'b, T, S, H> BitXor<&'b HashSet<T, S>> for &'a HashSet<T, S> where T: Eq + Hash<H> + Clone, S: HashState<Hasher=H> + Default, @@ -752,7 +752,7 @@ impl<'a, 'b, T, S, H> BitXor<&'b HashSet<T, S>> for &'a HashSet<T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, 'b, T, S, H> Sub<&'b HashSet<T, S>> for &'a HashSet<T, S> where T: Eq + Hash<H> + Clone, S: HashState<Hasher=H> + Default, @@ -786,25 +786,25 @@ impl<'a, 'b, T, S, H> Sub<&'b HashSet<T, S>> for &'a HashSet<T, S> } /// HashSet iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Iter<'a, K: 'a> { iter: Keys<'a, K, ()> } /// HashSet move iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct IntoIter<K> { iter: Map<(K, ()), K, map::IntoIter<K, ()>, fn((K, ())) -> K> } /// HashSet drain iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Drain<'a, K: 'a> { iter: Map<(K, ()), K, map::Drain<'a, K, ()>, fn((K, ())) -> K>, } /// Intersection iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Intersection<'a, T: 'a, S: 'a> { // iterator of the first set iter: Iter<'a, T>, @@ -813,7 +813,7 @@ pub struct Intersection<'a, T: 'a, S: 'a> { } /// Difference iterator -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Difference<'a, T: 'a, S: 'a> { // iterator of the first set iter: Iter<'a, T>, @@ -822,54 +822,54 @@ pub struct Difference<'a, T: 'a, S: 'a> { } /// Symmetric difference iterator. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct SymmetricDifference<'a, T: 'a, S: 'a> { iter: Chain<Difference<'a, T, S>, Difference<'a, T, S>> } /// Set union iterator. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Union<'a, T: 'a, S: 'a> { iter: Chain<Iter<'a, T>, Difference<'a, T, S>> } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K> Iterator for Iter<'a, K> { type Item = &'a K; fn next(&mut self) -> Option<&'a K> { self.iter.next() } fn size_hint(&self) -> (usize, Option<usize>) { self.iter.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K> ExactSizeIterator for Iter<'a, K> { fn len(&self) -> usize { self.iter.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K> Iterator for IntoIter<K> { type Item = K; fn next(&mut self) -> Option<K> { self.iter.next() } fn size_hint(&self) -> (usize, Option<usize>) { self.iter.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<K> ExactSizeIterator for IntoIter<K> { fn len(&self) -> usize { self.iter.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K> Iterator for Drain<'a, K> { type Item = K; fn next(&mut self) -> Option<K> { self.iter.next() } fn size_hint(&self) -> (usize, Option<usize>) { self.iter.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, K> ExactSizeIterator for Drain<'a, K> { fn len(&self) -> usize { self.iter.len() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T, S, H> Iterator for Intersection<'a, T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H>, @@ -894,7 +894,7 @@ impl<'a, T, S, H> Iterator for Intersection<'a, T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T, S, H> Iterator for Difference<'a, T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H>, @@ -919,7 +919,7 @@ impl<'a, T, S, H> Iterator for Difference<'a, T, S> } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T, S, H> Iterator for SymmetricDifference<'a, T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H>, @@ -931,7 +931,7 @@ impl<'a, T, S, H> Iterator for SymmetricDifference<'a, T, S> fn size_hint(&self) -> (usize, Option<usize>) { self.iter.size_hint() } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T, S, H> Iterator for Union<'a, T, S> where T: Eq + Hash<H>, S: HashState<Hasher=H>, diff --git a/src/libstd/collections/mod.rs b/src/libstd/collections/mod.rs index fae17af472c..1b8780120b1 100644 --- a/src/libstd/collections/mod.rs +++ b/src/libstd/collections/mod.rs @@ -309,7 +309,7 @@ //! } //! ``` -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] pub use core_collections::Bound; pub use core_collections::{BinaryHeap, Bitv, BitvSet, BTreeMap, BTreeSet}; @@ -323,13 +323,13 @@ pub use self::hash_set::HashSet; mod hash; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub mod hash_map { //! A hashmap pub use super::hash::map::*; } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub mod hash_set { //! A hashset pub use super::hash::set::*; diff --git a/src/libstd/error.rs b/src/libstd/error.rs index df949ab03aa..68ad3193e74 100644 --- a/src/libstd/error.rs +++ b/src/libstd/error.rs @@ -78,7 +78,7 @@ //! } //! ``` -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] use prelude::v1::*; @@ -100,22 +100,22 @@ pub trait Error { } /// A trait for types that can be converted from a given error type `E`. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub trait FromError<E> { /// Perform the conversion. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn from_error(err: E) -> Self; } // Any type is convertable from itself -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<E> FromError<E> for E { fn from_error(err: E) -> E { err } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Error for Utf8Error { fn description(&self) -> &str { match *self { @@ -127,13 +127,13 @@ impl Error for Utf8Error { fn detail(&self) -> Option<String> { Some(self.to_string()) } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Error for FromUtf8Error { fn description(&self) -> &str { "invalid utf-8" } fn detail(&self) -> Option<String> { Some(self.to_string()) } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Error for FromUtf16Error { fn description(&self) -> &str { "invalid utf-16" } } diff --git a/src/libstd/io/comm_adapters.rs b/src/libstd/io/comm_adapters.rs index 2cdad79c584..20901d9c50e 100644 --- a/src/libstd/io/comm_adapters.rs +++ b/src/libstd/io/comm_adapters.rs @@ -134,7 +134,7 @@ impl ChanWriter { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Clone for ChanWriter { fn clone(&self) -> ChanWriter { ChanWriter { tx: self.tx.clone() } diff --git a/src/libstd/io/mod.rs b/src/libstd/io/mod.rs index dc3cfa7ead8..0046a323d07 100644 --- a/src/libstd/io/mod.rs +++ b/src/libstd/io/mod.rs @@ -1814,9 +1814,9 @@ bitflags! { } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Default for FilePermission { - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] #[inline] fn default() -> FilePermission { FilePermission::empty() } } diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs index 643e10f0f29..d708f4df2a5 100644 --- a/src/libstd/lib.rs +++ b/src/libstd/lib.rs @@ -95,7 +95,7 @@ //! and `format!`, also available to all Rust code. #![crate_name = "std"] -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![feature(staged_api)] #![staged_api] #![crate_type = "rlib"] @@ -183,7 +183,7 @@ pub use alloc::rc; pub use core_collections::slice; pub use core_collections::str; pub use core_collections::string; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub use core_collections::vec; pub use unicode::char; diff --git a/src/libstd/macros.rs b/src/libstd/macros.rs index 7c9ee95bc20..5d1f2aa9b1e 100644 --- a/src/libstd/macros.rs +++ b/src/libstd/macros.rs @@ -36,7 +36,7 @@ /// panic!("this is a {} {message}", "fancy", message = "message"); /// ``` #[macro_export] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] macro_rules! panic { () => ({ panic!("explicit panic") @@ -71,7 +71,7 @@ macro_rules! panic { /// format!("x = {}, y = {y}", 10i, y = 30i); /// ``` #[macro_export] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] macro_rules! format { ($($arg:tt)*) => ($crate::fmt::format(format_args!($($arg)*))) } @@ -79,7 +79,7 @@ macro_rules! format { /// Equivalent to the `println!` macro except that a newline is not printed at /// the end of the message. #[macro_export] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] macro_rules! print { ($($arg:tt)*) => ($crate::io::stdio::print_args(format_args!($($arg)*))) } @@ -97,7 +97,7 @@ macro_rules! print { /// println!("format {} arguments", "some"); /// ``` #[macro_export] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] macro_rules! println { ($($arg:tt)*) => ($crate::io::stdio::println_args(format_args!($($arg)*))) } @@ -106,7 +106,7 @@ macro_rules! println { /// error if the value of the expression is `Err`. For more information, see /// `std::io`. #[macro_export] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] macro_rules! try { ($expr:expr) => (match $expr { $crate::result::Result::Ok(val) => val, diff --git a/src/libstd/num/f32.rs b/src/libstd/num/f32.rs index 5413f3a900f..9b5b0e62a3c 100644 --- a/src/libstd/num/f32.rs +++ b/src/libstd/num/f32.rs @@ -10,7 +10,7 @@ //! Operations and constants for 32-bits floats (`f32` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![allow(missing_docs)] #![allow(unsigned_negation)] #![doc(primitive = "f32")] @@ -73,7 +73,7 @@ mod cmath { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Float for f32 { #[inline] fn nan() -> f32 { num::Float::nan() } diff --git a/src/libstd/num/f64.rs b/src/libstd/num/f64.rs index 1fd4f056a2d..1c955832529 100644 --- a/src/libstd/num/f64.rs +++ b/src/libstd/num/f64.rs @@ -10,7 +10,7 @@ //! Operations and constants for 64-bits floats (`f64` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![allow(missing_docs)] #![doc(primitive = "f64")] @@ -81,7 +81,7 @@ mod cmath { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Float for f64 { // inlined methods from `num::Float` #[inline] diff --git a/src/libstd/num/i16.rs b/src/libstd/num/i16.rs index cd4e41432af..498f19b9b83 100644 --- a/src/libstd/num/i16.rs +++ b/src/libstd/num/i16.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 16-bits integers (`i16` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "i16")] pub use core::i16::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/i32.rs b/src/libstd/num/i32.rs index 89f3ab81c94..aea1e92117b 100644 --- a/src/libstd/num/i32.rs +++ b/src/libstd/num/i32.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 32-bits integers (`i32` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "i32")] pub use core::i32::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/i64.rs b/src/libstd/num/i64.rs index 6c866382ed3..43794345fe7 100644 --- a/src/libstd/num/i64.rs +++ b/src/libstd/num/i64.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 64-bits integers (`i64` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "i64")] pub use core::i64::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/i8.rs b/src/libstd/num/i8.rs index 521b24cdf73..1b03bf6f4f0 100644 --- a/src/libstd/num/i8.rs +++ b/src/libstd/num/i8.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 8-bits integers (`i8` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "i8")] pub use core::i8::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/isize.rs b/src/libstd/num/isize.rs index c0ae4d6a2cd..7fb2cd81aba 100644 --- a/src/libstd/num/isize.rs +++ b/src/libstd/num/isize.rs @@ -14,7 +14,7 @@ //! new type will gradually take place over the alpha cycle along with //! the development of clearer conventions around integer types. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "isize")] pub use core::isize::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/mod.rs b/src/libstd/num/mod.rs index 78ccaeef7bc..c81dfad63d7 100644 --- a/src/libstd/num/mod.rs +++ b/src/libstd/num/mod.rs @@ -13,7 +13,7 @@ //! These are implemented for the primitive numeric types in `std::{u8, u16, //! u32, u64, uint, i8, i16, i32, i64, int, f32, f64}`. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![allow(missing_docs)] #[cfg(test)] use fmt::Show; @@ -37,7 +37,7 @@ use option::Option; pub mod strconv; /// Mathematical operations on primitive floating point numbers. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub trait Float : Copy + Clone + NumCast @@ -142,7 +142,7 @@ pub trait Float #[unstable(feature = "std_misc", reason = "position is undecided")] fn is_normal(self) -> bool; /// Returns the category that this number falls into. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn classify(self) -> FpCategory; /// Returns the mantissa, exponent and sign as integers, respectively. @@ -150,40 +150,40 @@ pub trait Float fn integer_decode(self) -> (u64, i16, i8); /// Return the largest integer less than or equal to a number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn floor(self) -> Self; /// Return the smallest integer greater than or equal to a number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn ceil(self) -> Self; /// Return the nearest integer to a number. Round half-way cases away from /// `0.0`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn round(self) -> Self; /// Return the integer part of a number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn trunc(self) -> Self; /// Return the fractional part of a number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn fract(self) -> Self; /// Computes the absolute value of `self`. Returns `Float::nan()` if the /// number is `Float::nan()`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn abs(self) -> Self; /// Returns a number that represents the sign of `self`. /// /// - `1.0` if the number is positive, `+0.0` or `Float::infinity()` /// - `-1.0` if the number is negative, `-0.0` or `Float::neg_infinity()` /// - `Float::nan()` if the number is `Float::nan()` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn signum(self) -> Self; /// Returns `true` if `self` is positive, including `+0.0` and /// `Float::infinity()`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn is_positive(self) -> bool; /// Returns `true` if `self` is negative, including `-0.0` and /// `Float::neg_infinity()`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn is_negative(self) -> bool; /// Fused multiply-add. Computes `(self * a) + b` with only one rounding @@ -200,16 +200,16 @@ pub trait Float /// Raise a number to an integer power. /// /// Using this function is generally faster than using `powf` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn powi(self, n: i32) -> Self; /// Raise a number to a floating point power. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn powf(self, n: Self) -> Self; /// Take the square root of a number. /// /// Returns NaN if `self` is a negative number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn sqrt(self) -> Self; /// Take the reciprocal (inverse) square root of a number, `1/sqrt(x)`. #[unstable(feature = "std_misc", @@ -217,22 +217,22 @@ pub trait Float fn rsqrt(self) -> Self; /// Returns `e^(self)`, (the exponential function). - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn exp(self) -> Self; /// Returns 2 raised to the power of the number, `2^(self)`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn exp2(self) -> Self; /// Returns the natural logarithm of the number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn ln(self) -> Self; /// Returns the logarithm of the number with respect to an arbitrary base. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn log(self, base: Self) -> Self; /// Returns the base 2 logarithm of the number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn log2(self) -> Self; /// Returns the base 10 logarithm of the number. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn log10(self) -> Self; /// Convert radians to degrees. @@ -264,10 +264,10 @@ pub trait Float fn next_after(self, other: Self) -> Self; /// Returns the maximum of the two numbers. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn max(self, other: Self) -> Self; /// Returns the minimum of the two numbers. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn min(self, other: Self) -> Self; /// The positive difference of two numbers. Returns `0.0` if the number is @@ -286,36 +286,36 @@ pub trait Float fn hypot(self, other: Self) -> Self; /// Computes the sine of a number (in radians). - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn sin(self) -> Self; /// Computes the cosine of a number (in radians). - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn cos(self) -> Self; /// Computes the tangent of a number (in radians). - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn tan(self) -> Self; /// Computes the arcsine of a number. Return value is in radians in /// the range [-pi/2, pi/2] or NaN if the number is outside the range /// [-1, 1]. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn asin(self) -> Self; /// Computes the arccosine of a number. Return value is in radians in /// the range [0, pi] or NaN if the number is outside the range /// [-1, 1]. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn acos(self) -> Self; /// Computes the arctangent of a number. Return value is in radians in the /// range [-pi/2, pi/2]; - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn atan(self) -> Self; /// Computes the four quadrant arctangent of a number, `y`, and another /// number `x`. Return value is in radians in the range [-pi, pi]. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn atan2(self, other: Self) -> Self; /// Simultaneously computes the sine and cosine of the number, `x`. Returns /// `(sin(x), cos(x))`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn sin_cos(self) -> (Self, Self); /// Returns the exponential of the number, minus 1, in a way that is @@ -328,22 +328,22 @@ pub trait Float fn ln_1p(self) -> Self; /// Hyperbolic sine function. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn sinh(self) -> Self; /// Hyperbolic cosine function. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn cosh(self) -> Self; /// Hyperbolic tangent function. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn tanh(self) -> Self; /// Inverse hyperbolic sine function. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn asinh(self) -> Self; /// Inverse hyperbolic cosine function. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn acosh(self) -> Self; /// Inverse hyperbolic tangent function. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] fn atanh(self) -> Self; } diff --git a/src/libstd/num/u16.rs b/src/libstd/num/u16.rs index 06773a37ab5..3fda77fb69c 100644 --- a/src/libstd/num/u16.rs +++ b/src/libstd/num/u16.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 16-bits integers (`u16` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "u16")] pub use core::u16::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/u32.rs b/src/libstd/num/u32.rs index a58941b00f9..8610f0c0147 100644 --- a/src/libstd/num/u32.rs +++ b/src/libstd/num/u32.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 32-bits integers (`u32` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "u32")] pub use core::u32::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/u64.rs b/src/libstd/num/u64.rs index 2a42382dd8f..3587b069656 100644 --- a/src/libstd/num/u64.rs +++ b/src/libstd/num/u64.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 64-bits integer (`u64` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "u64")] pub use core::u64::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/u8.rs b/src/libstd/num/u8.rs index 952c8c0347f..6a285e8299c 100644 --- a/src/libstd/num/u8.rs +++ b/src/libstd/num/u8.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 8-bits integers (`u8` type) -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "u8")] pub use core::u8::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/num/usize.rs b/src/libstd/num/usize.rs index 52601a92ed4..19964c306a7 100644 --- a/src/libstd/num/usize.rs +++ b/src/libstd/num/usize.rs @@ -14,7 +14,7 @@ //! new type will gradually take place over the alpha cycle along with //! the development of clearer conventions around integer types. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] #![doc(primitive = "usize")] pub use core::usize::{BITS, BYTES, MIN, MAX}; diff --git a/src/libstd/prelude/mod.rs b/src/libstd/prelude/mod.rs index f5cf4447652..09fa10dacf9 100644 --- a/src/libstd/prelude/mod.rs +++ b/src/libstd/prelude/mod.rs @@ -35,6 +35,6 @@ //! pervasive that it would be obnoxious to import for every use, particularly //! those that define methods on primitive types. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] pub mod v1; diff --git a/src/libstd/prelude/v1.rs b/src/libstd/prelude/v1.rs index 3251656cd16..51cf173ca94 100644 --- a/src/libstd/prelude/v1.rs +++ b/src/libstd/prelude/v1.rs @@ -10,12 +10,12 @@ //! The first version of the prelude of the standard library. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] // Reexported core operators -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use marker::{Copy, Send, Sized, Sync}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use ops::{Drop, Fn, FnMut, FnOnce}; // TEMPORARY @@ -23,40 +23,40 @@ #[doc(no_inline)] pub use ops::FullRange; // Reexported functions -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use mem::drop; // Reexported types and traits -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use boxed::Box; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use char::CharExt; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use clone::Clone; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use cmp::{PartialEq, PartialOrd, Eq, Ord}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use iter::DoubleEndedIterator; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use iter::ExactSizeIterator; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use iter::{Iterator, IteratorExt, Extend}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use option::Option::{self, Some, None}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use ptr::{PtrExt, MutPtrExt}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use result::Result::{self, Ok, Err}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use slice::AsSlice; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use slice::{SliceExt, SliceConcatExt}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use str::{Str, StrExt}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use string::{String, ToString}; -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use vec::Vec; // NB: remove when path reform lands diff --git a/src/libstd/sync/barrier.rs b/src/libstd/sync/barrier.rs index c65a772da04..40710d627c0 100644 --- a/src/libstd/sync/barrier.rs +++ b/src/libstd/sync/barrier.rs @@ -29,7 +29,7 @@ use sync::{Mutex, Condvar}; /// }); /// } /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Barrier { lock: Mutex<BarrierState>, cvar: Condvar, @@ -54,7 +54,7 @@ impl Barrier { /// /// A barrier will block `n`-1 threads which call `wait` and then wake up /// all threads at once when the `n`th thread calls `wait`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn new(n: uint) -> Barrier { Barrier { lock: Mutex::new(BarrierState { @@ -75,7 +75,7 @@ impl Barrier { /// returns `true` from `is_leader` when returning from this function, and /// all other threads will receive a result that will return `false` from /// `is_leader` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn wait(&self) -> BarrierWaitResult { let mut lock = self.lock.lock().unwrap(); let local_gen = lock.generation_id; @@ -102,7 +102,7 @@ impl BarrierWaitResult { /// /// Only one thread will have `true` returned from their result, all other /// threads will have `false` returned. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn is_leader(&self) -> bool { self.0 } } diff --git a/src/libstd/sync/condvar.rs b/src/libstd/sync/condvar.rs index e36dd943386..a7a5b084582 100644 --- a/src/libstd/sync/condvar.rs +++ b/src/libstd/sync/condvar.rs @@ -58,7 +58,7 @@ use sync::{mutex, MutexGuard}; /// started = cvar.wait(started).unwrap(); /// } /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Condvar { inner: Box<StaticCondvar> } unsafe impl Send for Condvar {} @@ -97,7 +97,7 @@ pub const CONDVAR_INIT: StaticCondvar = StaticCondvar { impl Condvar { /// Creates a new condition variable which is ready to be waited on and /// notified. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn new() -> Condvar { Condvar { inner: box StaticCondvar { @@ -133,7 +133,7 @@ impl Condvar { /// over time. Each condition variable is dynamically bound to exactly one /// mutex to ensure defined behavior across platforms. If this functionality /// is not desired, then unsafe primitives in `sys` are provided. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn wait<'a, T>(&self, guard: MutexGuard<'a, T>) -> LockResult<MutexGuard<'a, T>> { unsafe { @@ -191,7 +191,7 @@ impl Condvar { /// `notify_one` are not buffered in any way. /// /// To wake up all threads, see `notify_all()`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn notify_one(&self) { unsafe { self.inner.inner.notify_one() } } /// Wake up all blocked threads on this condvar. @@ -201,11 +201,11 @@ impl Condvar { /// way. /// /// To wake up only one thread, see `notify_one()`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn notify_all(&self) { unsafe { self.inner.inner.notify_all() } } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl Drop for Condvar { fn drop(&mut self) { unsafe { self.inner.inner.destroy() } diff --git a/src/libstd/sync/mod.rs b/src/libstd/sync/mod.rs index 9e9d204aa46..f3b721438d8 100644 --- a/src/libstd/sync/mod.rs +++ b/src/libstd/sync/mod.rs @@ -15,7 +15,7 @@ //! and/or blocking at all, but rather provide the necessary tools to build //! other types of concurrent primitives. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] pub use alloc::arc::{Arc, Weak}; pub use core::atomic; diff --git a/src/libstd/sync/mpsc/mod.rs b/src/libstd/sync/mpsc/mod.rs index 73ddd2e4c45..8fce8cbabcc 100644 --- a/src/libstd/sync/mpsc/mod.rs +++ b/src/libstd/sync/mpsc/mod.rs @@ -163,7 +163,7 @@ //! } //! ``` -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] // A description of how Rust's channel implementation works // @@ -339,7 +339,7 @@ mod spsc_queue; /// The receiving-half of Rust's channel type. This half can only be owned by /// one task -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Receiver<T> { inner: UnsafeCell<Flavor<T>>, } @@ -351,14 +351,14 @@ unsafe impl<T:Send> Send for Receiver<T> { } /// An iterator over messages on a receiver, this iterator will block /// whenever `next` is called, waiting for a new message, and `None` will be /// returned when the corresponding channel has hung up. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Iter<'a, T:'a> { rx: &'a Receiver<T> } /// The sending-half of Rust's asynchronous channel type. This half can only be /// owned by one task, but it can be cloned to send to other tasks. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Sender<T> { inner: UnsafeCell<Flavor<T>>, } @@ -370,7 +370,7 @@ unsafe impl<T:Send> Send for Sender<T> { } /// The sending-half of Rust's synchronous channel type. This half can only be /// owned by one task, but it can be cloned to send to other tasks. #[cfg(stage0)] // NOTE remove impl after next snapshot -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct SyncSender<T> { inner: Arc<RacyCell<sync::Packet<T>>>, // can't share in an arc @@ -379,7 +379,7 @@ pub struct SyncSender<T> { /// The sending-half of Rust's synchronous channel type. This half can only be /// owned by one task, but it can be cloned to send to other tasks. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[cfg(not(stage0))] // NOTE remove cfg after next snapshot pub struct SyncSender<T> { inner: Arc<RacyCell<sync::Packet<T>>>, @@ -394,7 +394,7 @@ impl<T> !marker::Sync for SyncSender<T> {} /// disconnected, implying that the data could never be received. The error /// contains the data being sent as a payload so it can be recovered. #[derive(PartialEq, Eq)] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct SendError<T>(pub T); /// An error returned from the `recv` function on a `Receiver`. @@ -402,29 +402,29 @@ pub struct SendError<T>(pub T); /// The `recv` operation can only fail if the sending half of a channel is /// disconnected, implying that no further messages will ever be received. #[derive(PartialEq, Eq, Clone, Copy)] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct RecvError; /// This enumeration is the list of the possible reasons that try_recv could not /// return data when called. #[derive(PartialEq, Clone, Copy)] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub enum TryRecvError { /// This channel is currently empty, but the sender(s) have not yet /// disconnected, so data may yet become available. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] Empty, /// This channel's sending half has become disconnected, and there will /// never be any more data received on this channel - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] Disconnected, } /// This enumeration is the list of the possible error outcomes for the /// `SyncSender::try_send` method. #[derive(PartialEq, Clone)] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub enum TrySendError<T> { /// The data could not be sent on the channel because it would require that /// the callee block to send the data. @@ -432,12 +432,12 @@ pub enum TrySendError<T> { /// If this is a buffered channel, then the buffer is full at this time. If /// this is not a buffered channel, then there is no receiver available to /// acquire the data. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] Full(T), /// This channel's receiving half has disconnected, so the data could not be /// sent. The data is returned back to the callee in this case. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] Disconnected(T), } @@ -495,7 +495,7 @@ impl<T> UnsafeFlavor<T> for Receiver<T> { /// // Let's see what that answer was /// println!("{:?}", rx.recv().unwrap()); /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub fn channel<T: Send>() -> (Sender<T>, Receiver<T>) { let a = Arc::new(RacyCell::new(oneshot::Packet::new())); (Sender::new(Flavor::Oneshot(a.clone())), Receiver::new(Flavor::Oneshot(a))) @@ -535,7 +535,7 @@ pub fn channel<T: Send>() -> (Sender<T>, Receiver<T>) { /// assert_eq!(rx.recv().unwrap(), 1i); /// assert_eq!(rx.recv().unwrap(), 2i); /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub fn sync_channel<T: Send>(bound: uint) -> (SyncSender<T>, Receiver<T>) { let a = Arc::new(RacyCell::new(sync::Packet::new(bound))); (SyncSender::new(a.clone()), Receiver::new(Flavor::Sync(a))) @@ -579,7 +579,7 @@ impl<T: Send> Sender<T> { /// drop(rx); /// assert_eq!(tx.send(1i).err().unwrap().0, 1); /// ``` - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn send(&self, t: T) -> Result<(), SendError<T>> { let (new_inner, ret) = match *unsafe { self.inner() } { Flavor::Oneshot(ref p) => { @@ -626,7 +626,7 @@ impl<T: Send> Sender<T> { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T: Send> Clone for Sender<T> { fn clone(&self) -> Sender<T> { let (packet, sleeper, guard) = match *unsafe { self.inner() } { @@ -672,7 +672,7 @@ impl<T: Send> Clone for Sender<T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T: Send> Drop for Sender<T> { fn drop(&mut self) { match *unsafe { self.inner_mut() } { @@ -713,7 +713,7 @@ impl<T: Send> SyncSender<T> { /// This function will never panic, but it may return `Err` if the /// `Receiver` has disconnected and is no longer able to receive /// information. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn send(&self, t: T) -> Result<(), SendError<T>> { unsafe { (*self.inner.get()).send(t).map_err(SendError) } } @@ -727,13 +727,13 @@ impl<T: Send> SyncSender<T> { /// /// See `SyncSender::send` for notes about guarantees of whether the /// receiver has received the data or not if this function is successful. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn try_send(&self, t: T) -> Result<(), TrySendError<T>> { unsafe { (*self.inner.get()).try_send(t) } } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T: Send> Clone for SyncSender<T> { fn clone(&self) -> SyncSender<T> { unsafe { (*self.inner.get()).clone_chan(); } @@ -742,7 +742,7 @@ impl<T: Send> Clone for SyncSender<T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T: Send> Drop for SyncSender<T> { fn drop(&mut self) { unsafe { (*self.inner.get()).drop_chan(); } @@ -766,7 +766,7 @@ impl<T: Send> Receiver<T> { /// /// This is useful for a flavor of "optimistic check" before deciding to /// block on a receiver. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn try_recv(&self) -> Result<T, TryRecvError> { loop { let new_port = match *unsafe { self.inner() } { @@ -827,7 +827,7 @@ impl<T: Send> Receiver<T> { /// If the corresponding `Sender` has disconnected, or it disconnects while /// this call is blocking, this call will wake up and return `Err` to /// indicate that no more messages can ever be received on this channel. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn recv(&self) -> Result<T, RecvError> { loop { let new_port = match *unsafe { self.inner() } { @@ -866,7 +866,7 @@ impl<T: Send> Receiver<T> { /// Returns an iterator that will block waiting for messages, but never /// `panic!`. It will return `None` when the channel has hung up. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn iter(&self) -> Iter<T> { Iter { rx: self } } @@ -958,7 +958,7 @@ impl<T: Send> select::Packet for Receiver<T> { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T: Send> Iterator for Iter<'a, T> { type Item = T; @@ -966,7 +966,7 @@ impl<'a, T: Send> Iterator for Iter<'a, T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T: Send> Drop for Receiver<T> { fn drop(&mut self) { match *unsafe { self.inner_mut() } { diff --git a/src/libstd/sync/mpsc/mpsc_queue.rs b/src/libstd/sync/mpsc/mpsc_queue.rs index 8afd8e59979..92aec5cde07 100644 --- a/src/libstd/sync/mpsc/mpsc_queue.rs +++ b/src/libstd/sync/mpsc/mpsc_queue.rs @@ -138,7 +138,7 @@ impl<T: Send> Queue<T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T: Send> Drop for Queue<T> { fn drop(&mut self) { unsafe { diff --git a/src/libstd/sync/mutex.rs b/src/libstd/sync/mutex.rs index 0d18c05f71a..d74e030a018 100644 --- a/src/libstd/sync/mutex.rs +++ b/src/libstd/sync/mutex.rs @@ -109,7 +109,7 @@ use sys_common::mutex as sys; /// /// *guard += 1; /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Mutex<T> { // Note that this static mutex is in a *box*, not inlined into the struct // itself. Once a native mutex has been used once, its address can never @@ -161,7 +161,7 @@ unsafe impl Sync for StaticMutex {} /// Deref and DerefMut implementations #[must_use] #[cfg(stage0)] // NOTE remove impl after next snapshot -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct MutexGuard<'a, T: 'a> { // funny underscores due to how Deref/DerefMut currently work (they // disregard field privacy). @@ -177,7 +177,7 @@ pub struct MutexGuard<'a, T: 'a> { /// The data protected by the mutex can be access through this guard via its /// Deref and DerefMut implementations #[must_use] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[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 @@ -201,7 +201,7 @@ pub const MUTEX_INIT: StaticMutex = StaticMutex { impl<T: Send> Mutex<T> { /// Creates a new mutex in an unlocked state ready for use. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn new(t: T) -> Mutex<T> { Mutex { inner: box MUTEX_INIT, @@ -220,7 +220,7 @@ impl<T: Send> Mutex<T> { /// /// If another user of this mutex panicked while holding the mutex, then /// this call will return an error once the mutex is acquired. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn lock(&self) -> LockResult<MutexGuard<T>> { unsafe { self.inner.lock.lock() } MutexGuard::new(&*self.inner, &self.data) @@ -239,7 +239,7 @@ impl<T: Send> Mutex<T> { /// If another user of this mutex panicked while holding the mutex, then /// this call will return failure if the mutex would otherwise be /// acquired. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn try_lock(&self) -> TryLockResult<MutexGuard<T>> { if unsafe { self.inner.lock.try_lock() } { Ok(try!(MutexGuard::new(&*self.inner, &self.data))) @@ -250,7 +250,7 @@ impl<T: Send> Mutex<T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T: Send> Drop for Mutex<T> { fn drop(&mut self) { // This is actually safe b/c we know that there is no further usage of @@ -330,7 +330,7 @@ impl<'mutex, T> MutexGuard<'mutex, T> { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'mutex, T> Deref for MutexGuard<'mutex, T> { type Target = T; @@ -338,7 +338,7 @@ impl<'mutex, T> Deref for MutexGuard<'mutex, T> { unsafe { &*self.__data.get() } } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'mutex, T> DerefMut for MutexGuard<'mutex, T> { fn deref_mut<'a>(&'a mut self) -> &'a mut T { unsafe { &mut *self.__data.get() } @@ -346,7 +346,7 @@ impl<'mutex, T> DerefMut for MutexGuard<'mutex, T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T> Drop for MutexGuard<'a, T> { #[inline] fn drop(&mut self) { diff --git a/src/libstd/sync/once.rs b/src/libstd/sync/once.rs index 82ed62966b5..1c489540581 100644 --- a/src/libstd/sync/once.rs +++ b/src/libstd/sync/once.rs @@ -36,7 +36,7 @@ use sync::{StaticMutex, MUTEX_INIT}; /// // run initialization here /// }); /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Once { mutex: StaticMutex, cnt: AtomicIsize, @@ -46,7 +46,7 @@ pub struct Once { unsafe impl Sync for Once {} /// Initialization value for static `Once` values. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub const ONCE_INIT: Once = Once { mutex: MUTEX_INIT, cnt: ATOMIC_ISIZE_INIT, @@ -63,7 +63,7 @@ impl Once { /// /// When this function returns, it is guaranteed that some initialization /// has run and completed (it may not be the closure specified). - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn call_once<F>(&'static self, f: F) where F: FnOnce() { // Optimize common path: load is much cheaper than fetch_add. if self.cnt.load(Ordering::SeqCst) < 0 { diff --git a/src/libstd/sync/poison.rs b/src/libstd/sync/poison.rs index f5bb7a56d77..6c5cb302ab1 100644 --- a/src/libstd/sync/poison.rs +++ b/src/libstd/sync/poison.rs @@ -53,22 +53,22 @@ pub struct Guard { /// is held. The precise semantics for when a lock is poisoned is documented on /// each lock, but once a lock is poisoned then all future acquisitions will /// return this error. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct PoisonError<T> { guard: T, } /// An enumeration of possible errors which can occur while calling the /// `try_lock` method. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub enum TryLockError<T> { /// The lock could not be acquired because another task failed while holding /// the lock. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] Poisoned(PoisonError<T>), /// The lock could not be acquired at this time because the operation would /// otherwise block. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] WouldBlock, } @@ -79,7 +79,7 @@ pub enum TryLockError<T> { /// that the primitive was poisoned. Note that the `Err` variant *also* carries /// the associated guard, and it can be acquired through the `into_inner` /// method. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub type LockResult<Guard> = Result<Guard, PoisonError<Guard>>; /// A type alias for the result of a nonblocking locking method. @@ -87,7 +87,7 @@ pub type LockResult<Guard> = Result<Guard, PoisonError<Guard>>; /// For more information, see `LockResult`. A `TryLockResult` doesn't /// necessarily hold the associated guard in the `Err` type as the lock may not /// have been acquired for other reasons. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub type TryLockResult<Guard> = Result<Guard, TryLockError<Guard>>; impl<T> fmt::Show for PoisonError<T> { diff --git a/src/libstd/sync/rwlock.rs b/src/libstd/sync/rwlock.rs index abed6fd99a5..01389047df6 100644 --- a/src/libstd/sync/rwlock.rs +++ b/src/libstd/sync/rwlock.rs @@ -58,7 +58,7 @@ use sys_common::rwlock as sys; /// assert_eq!(*w, 6); /// } // write lock is dropped here /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct RwLock<T> { inner: Box<StaticRwLock>, data: UnsafeCell<T>, @@ -111,7 +111,7 @@ pub const RW_LOCK_INIT: StaticRwLock = StaticRwLock { /// RAII structure used to release the shared read access of a lock when /// dropped. #[must_use] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[cfg(stage0)] // NOTE remove impl after next snapshot pub struct RwLockReadGuard<'a, T: 'a> { __lock: &'a StaticRwLock, @@ -123,7 +123,7 @@ pub struct RwLockReadGuard<'a, T: 'a> { /// dropped. #[must_use] #[cfg(not(stage0))] // NOTE remove cfg after next snapshot -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct RwLockReadGuard<'a, T: 'a> { __lock: &'a StaticRwLock, __data: &'a UnsafeCell<T>, @@ -136,7 +136,7 @@ impl<'a, T> !marker::Send for RwLockReadGuard<'a, T> {} /// dropped. #[must_use] #[cfg(stage0)] // NOTE remove impl after next snapshot -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct RwLockWriteGuard<'a, T: 'a> { __lock: &'a StaticRwLock, __data: &'a UnsafeCell<T>, @@ -147,7 +147,7 @@ pub struct RwLockWriteGuard<'a, T: 'a> { /// RAII structure used to release the exclusive write access of a lock when /// dropped. #[must_use] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] #[cfg(not(stage0))] // NOTE remove cfg after next snapshot pub struct RwLockWriteGuard<'a, T: 'a> { __lock: &'a StaticRwLock, @@ -160,7 +160,7 @@ impl<'a, T> !marker::Send for RwLockWriteGuard<'a, T> {} impl<T: Send + Sync> RwLock<T> { /// Creates a new instance of an RwLock which is unlocked and read to go. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn new(t: T) -> RwLock<T> { RwLock { inner: box RW_LOCK_INIT, data: UnsafeCell::new(t) } } @@ -183,7 +183,7 @@ impl<T: Send + Sync> RwLock<T> { /// is poisoned whenever a writer panics while holding an exclusive lock. /// The failure will occur immediately after the lock has been acquired. #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn read(&self) -> LockResult<RwLockReadGuard<T>> { unsafe { self.inner.lock.read() } RwLockReadGuard::new(&*self.inner, &self.data) @@ -205,7 +205,7 @@ impl<T: Send + Sync> RwLock<T> { /// error will only be returned if the lock would have otherwise been /// acquired. #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn try_read(&self) -> TryLockResult<RwLockReadGuard<T>> { if unsafe { self.inner.lock.try_read() } { Ok(try!(RwLockReadGuard::new(&*self.inner, &self.data))) @@ -229,7 +229,7 @@ impl<T: Send + Sync> RwLock<T> { /// is poisoned whenever a writer panics while holding an exclusive lock. /// An error will be returned when the lock is acquired. #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn write(&self) -> LockResult<RwLockWriteGuard<T>> { unsafe { self.inner.lock.write() } RwLockWriteGuard::new(&*self.inner, &self.data) @@ -248,7 +248,7 @@ impl<T: Send + Sync> RwLock<T> { /// error will only be returned if the lock would have otherwise been /// acquired. #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn try_write(&self) -> TryLockResult<RwLockWriteGuard<T>> { if unsafe { self.inner.lock.try_read() } { Ok(try!(RwLockWriteGuard::new(&*self.inner, &self.data))) @@ -259,7 +259,7 @@ impl<T: Send + Sync> RwLock<T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<T> Drop for RwLock<T> { fn drop(&mut self) { unsafe { self.inner.lock.destroy() } @@ -389,19 +389,19 @@ impl<'rwlock, T> RwLockWriteGuard<'rwlock, T> { } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'rwlock, T> Deref for RwLockReadGuard<'rwlock, T> { type Target = T; fn deref(&self) -> &T { unsafe { &*self.__data.get() } } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'rwlock, T> Deref for RwLockWriteGuard<'rwlock, T> { type Target = T; fn deref(&self) -> &T { unsafe { &*self.__data.get() } } } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'rwlock, T> DerefMut for RwLockWriteGuard<'rwlock, T> { fn deref_mut(&mut self) -> &mut T { unsafe { &mut *self.__data.get() } @@ -409,7 +409,7 @@ impl<'rwlock, T> DerefMut for RwLockWriteGuard<'rwlock, T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T> Drop for RwLockReadGuard<'a, T> { fn drop(&mut self) { unsafe { self.__lock.lock.read_unlock(); } @@ -417,7 +417,7 @@ impl<'a, T> Drop for RwLockReadGuard<'a, T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T> Drop for RwLockWriteGuard<'a, T> { fn drop(&mut self) { self.__lock.poison.done(&self.__poison); diff --git a/src/libstd/sync/semaphore.rs b/src/libstd/sync/semaphore.rs index 25f31d6e147..0304b898884 100644 --- a/src/libstd/sync/semaphore.rs +++ b/src/libstd/sync/semaphore.rs @@ -100,7 +100,7 @@ impl Semaphore { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a> Drop for SemaphoreGuard<'a> { fn drop(&mut self) { self.sem.release(); diff --git a/src/libstd/thread.rs b/src/libstd/thread.rs index 1012edfc2fe..ec2718bef69 100644 --- a/src/libstd/thread.rs +++ b/src/libstd/thread.rs @@ -144,7 +144,7 @@ //! //! * It can be implemented highly efficiently on many platforms. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] use any::Any; use boxed::Box; @@ -166,7 +166,7 @@ use sys_common::{stack, thread_info}; /// Thread configuration. Provides detailed control over the properties /// and behavior of new threads. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Builder { // A name for the thread-to-be, for identification in panic messages name: Option<String>, @@ -181,7 +181,7 @@ pub struct Builder { impl Builder { /// Generate the base configuration for spawning a thread, from which /// configuration methods can be chained. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn new() -> Builder { Builder { name: None, @@ -193,14 +193,14 @@ impl Builder { /// Name the thread-to-be. Currently the name is used for identification /// only in panic messages. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn name(mut self, name: String) -> Builder { self.name = Some(name); self } /// Set the size of the stack for the new thread. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn stack_size(mut self, size: uint) -> Builder { self.stack_size = Some(size); self @@ -330,7 +330,7 @@ struct Inner { unsafe impl Sync for Inner {} #[derive(Clone)] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] /// A handle to a thread. pub struct Thread { inner: Arc<Inner>, @@ -377,7 +377,7 @@ impl Thread { } /// Gets a handle to the thread that invokes it. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn current() -> Thread { thread_info::current_thread() } @@ -390,7 +390,7 @@ impl Thread { /// Determines whether the current thread is panicking. #[inline] - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn panicking() -> bool { unwind::panicking() } @@ -427,7 +427,7 @@ impl Thread { } /// Get the thread's name. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn name(&self) -> Option<&str> { self.inner.name.as_ref().map(|s| s.as_slice()) } @@ -441,7 +441,7 @@ impl thread_info::NewThread for Thread { /// Indicates the manner in which a thread exited. /// /// A thread that completes without panicking is considered to exit successfully. -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub type Result<T> = ::result::Result<T, Box<Any + Send>>; struct Packet<T>(Arc<UnsafeCell<Option<Result<T>>>>); @@ -462,12 +462,12 @@ pub struct JoinGuard<'a, T: 'a> { packet: Packet<T>, } -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] unsafe impl<'a, T: Send + 'a> Sync for JoinGuard<'a, T> {} impl<'a, T: Send + 'a> JoinGuard<'a, T> { /// Extract a handle to the thread this guard will join on. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn thread(&self) -> &Thread { &self.thread } @@ -477,7 +477,7 @@ impl<'a, T: Send + 'a> JoinGuard<'a, T> { /// /// If the child thread panics, `Err` is returned with the parameter given /// to `panic`. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn join(mut self) -> Result<T> { assert!(!self.joined); unsafe { imp::join(self.native) }; @@ -499,7 +499,7 @@ impl<T: Send> JoinGuard<'static, T> { } #[unsafe_destructor] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] impl<'a, T: Send + 'a> Drop for JoinGuard<'a, T> { fn drop(&mut self) { if !self.joined { diff --git a/src/libstd/thread_local/mod.rs b/src/libstd/thread_local/mod.rs index bb8f73214d0..f7be63212ab 100644 --- a/src/libstd/thread_local/mod.rs +++ b/src/libstd/thread_local/mod.rs @@ -34,7 +34,7 @@ //! will want to make use of some form of **interior mutability** through the //! `Cell` or `RefCell` types. -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] use prelude::v1::*; @@ -93,7 +93,7 @@ pub mod __impl { /// assert_eq!(*f.borrow(), 2); /// }); /// ``` -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] pub struct Key<T> { // The key itself may be tagged with #[thread_local], and this `Key` is // stored as a `static`, and it's not valid for a static to reference the @@ -113,7 +113,7 @@ pub struct Key<T> { /// Declare a new thread local storage key of type `std::thread_local::Key`. #[macro_export] -#[stable(feature = "grandfathered", since = "1.0.0")] +#[stable(feature = "rust1", since = "1.0.0")] macro_rules! thread_local { (static $name:ident: $t:ty = $init:expr) => ( static $name: ::std::thread_local::Key<$t> = { @@ -259,7 +259,7 @@ impl<T: 'static> Key<T> { /// This function will `panic!()` if the key currently has its /// destructor running, and it **may** panic if the destructor has /// previously been run for this thread. - #[stable(feature = "grandfathered", since = "1.0.0")] + #[stable(feature = "rust1", since = "1.0.0")] pub fn with<F, R>(&'static self, f: F) -> R where F: FnOnce(&T) -> R { let slot = (self.inner)(); diff --git a/src/libstd/tuple.rs b/src/libstd/tuple.rs index b06deb738fc..2a911557765 100644 --- a/src/libstd/tuple.rs +++ b/src/libstd/tuple.rs @@ -57,4 +57,4 @@ //! ``` #![doc(primitive = "tuple")] -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] diff --git a/src/libstd/unit.rs b/src/libstd/unit.rs index 0893fe8ea06..2c3ddcd9d49 100644 --- a/src/libstd/unit.rs +++ b/src/libstd/unit.rs @@ -9,7 +9,7 @@ // except according to those terms. #![doc(primitive = "unit")] -#![stable(feature = "grandfathered", since = "1.0.0")] +#![stable(feature = "rust1", since = "1.0.0")] //! The `()` type, sometimes called "unit" or "nil". //! |
