Skip to content

Commit cad7914

Browse files
committed
---
yaml --- r: 275166 b: refs/heads/stable c: 0ef8d42 h: refs/heads/master
1 parent 42eac5d commit cad7914

File tree

59 files changed

+1253
-612
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+1253
-612
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/heads/tmp: e06d2ad9fcd5027bcaac5b08fc9aa39a49d0ecd3
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: c0221c8897db309a79990367476177b1230bb264
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828
32-
refs/heads/stable: 15f387d2cd087ba64ca88c1d8c6d47518296386e
32+
refs/heads/stable: 0ef8d426050318934d16d962325ec002eaf0c29d
3333
refs/tags/1.0.0: 55bd4f8ff2b323f317ae89e254ce87162d52a375
3434
refs/tags/1.1.0: bc3c16f09287e5545c1d3f76b7abd54f2eca868b
3535
refs/tags/1.2.0: f557861f822c34f07270347b94b5280de20a597e

branches/stable/mk/cfg/armv7-unknown-linux-gnueabihf.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ CFG_UNIXY_armv7-unknown-linux-gnueabihf := 1
2121
CFG_LDPATH_armv7-unknown-linux-gnueabihf :=
2222
CFG_RUN_armv7-unknown-linux-gnueabihf=$(2)
2323
CFG_RUN_TARG_armv7-unknown-linux-gnueabihf=$(call CFG_RUN_armv7-unknown-linux-gnueabihf,,$(2))
24-
RUSTC_FLAGS_armv7-unknown-linux-gnueabihf := -C target-feature=+v7,+vfp2,+neon
24+
RUSTC_FLAGS_armv7-unknown-linux-gnueabihf :=
2525
RUSTC_CROSS_FLAGS_armv7-unknown-linux-gnueabihf :=
2626
CFG_GNU_TRIPLE_armv7-unknown-linux-gnueabihf := armv7-unknown-linux-gnueabihf

branches/stable/src/etc/licenseck.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
# except according to those terms.
1010

1111
import re
12+
import os
1213

1314
license_re = re.compile(
1415
u"""(#|//) Copyright .* The Rust Project Developers. See the COPYRIGHT
@@ -40,8 +41,9 @@
4041
]
4142

4243
def check_license(name, contents):
44+
name = os.path.normpath(name)
4345
# Whitelist check
44-
if any(name.endswith(e) for e in exceptions):
46+
if any(name.endswith(os.path.normpath(e)) for e in exceptions):
4547
return True
4648

4749
# Xfail check

branches/stable/src/etc/tidy.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,8 @@ def interesting_file(f):
122122
'src/liblibc',
123123
}
124124

125-
if any(d in dirpath for d in skippable_dirs):
125+
dirpath = os.path.normpath(dirpath)
126+
if any(os.path.normpath(d) in dirpath for d in skippable_dirs):
126127
continue
127128

128129
file_names = [os.path.join(dirpath, f) for f in filenames

branches/stable/src/libcollections/borrow.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,12 +95,12 @@ pub enum Cow<'a, B: ?Sized + 'a>
9595
{
9696
/// Borrowed data.
9797
#[stable(feature = "rust1", since = "1.0.0")]
98-
Borrowed(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a B),
98+
Borrowed(#[stable(feature = "rust1", since = "1.0.0")] &'a B),
9999

100100
/// Owned data.
101101
#[stable(feature = "rust1", since = "1.0.0")]
102102
Owned(
103-
#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] <B as ToOwned>::Owned
103+
#[stable(feature = "rust1", since = "1.0.0")] <B as ToOwned>::Owned
104104
),
105105
}
106106

branches/stable/src/libcollections/btree/map.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -238,13 +238,13 @@ pub enum Entry<'a, K: 'a, V: 'a> {
238238
/// A vacant Entry
239239
#[stable(feature = "rust1", since = "1.0.0")]
240240
Vacant(
241-
#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] VacantEntry<'a, K, V>
241+
#[stable(feature = "rust1", since = "1.0.0")] VacantEntry<'a, K, V>
242242
),
243243

244244
/// An occupied Entry
245245
#[stable(feature = "rust1", since = "1.0.0")]
246246
Occupied(
247-
#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] OccupiedEntry<'a, K, V>
247+
#[stable(feature = "rust1", since = "1.0.0")] OccupiedEntry<'a, K, V>
248248
),
249249
}
250250

branches/stable/src/libcollections/vec.rs

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,10 @@
5959
6060
#![stable(feature = "rust1", since = "1.0.0")]
6161

62-
use alloc::raw_vec::RawVec;
6362
use alloc::boxed::Box;
6463
use alloc::heap::EMPTY;
64+
use alloc::raw_vec::RawVec;
65+
use borrow::ToOwned;
6566
use core::cmp::Ordering;
6667
use core::fmt;
6768
use core::hash::{self, Hash};
@@ -1633,6 +1634,15 @@ impl<T> DoubleEndedIterator for IntoIter<T> {
16331634
#[stable(feature = "rust1", since = "1.0.0")]
16341635
impl<T> ExactSizeIterator for IntoIter<T> {}
16351636

1637+
#[stable(feature = "vec_into_iter_clone", since = "1.8.0")]
1638+
impl<T: Clone> Clone for IntoIter<T> {
1639+
fn clone(&self) -> IntoIter<T> {
1640+
unsafe {
1641+
slice::from_raw_parts(self.ptr, self.len()).to_owned().into_iter()
1642+
}
1643+
}
1644+
}
1645+
16361646
#[stable(feature = "rust1", since = "1.0.0")]
16371647
impl<T> Drop for IntoIter<T> {
16381648
#[unsafe_destructor_blind_to_params]

branches/stable/src/libcollectionstest/vec.rs

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -467,6 +467,24 @@ fn test_into_iter_count() {
467467
assert_eq!(vec![1, 2, 3].into_iter().count(), 3);
468468
}
469469

470+
#[test]
471+
fn test_into_iter_clone() {
472+
fn iter_equal<I: Iterator<Item=i32>>(it: I, slice: &[i32]) {
473+
let v: Vec<i32> = it.collect();
474+
assert_eq!(&v[..], slice);
475+
}
476+
let mut it = vec![1, 2, 3].into_iter();
477+
iter_equal(it.clone(), &[1, 2, 3]);
478+
assert_eq!(it.next(), Some(1));
479+
let mut it = it.rev();
480+
iter_equal(it.clone(), &[3, 2]);
481+
assert_eq!(it.next(), Some(3));
482+
iter_equal(it.clone(), &[2]);
483+
assert_eq!(it.next(), Some(2));
484+
iter_equal(it.clone(), &[]);
485+
assert_eq!(it.next(), None);
486+
}
487+
470488
#[test]
471489
fn test_cow_from() {
472490
let borrowed: &[_] = &["borrowed", "(slice)"];

branches/stable/src/libcore/intrinsics.rs

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,33 @@ extern "rust-intrinsic" {
5858
pub fn atomic_cxchg_rel<T>(dst: *mut T, old: T, src: T) -> T;
5959
pub fn atomic_cxchg_acqrel<T>(dst: *mut T, old: T, src: T) -> T;
6060
pub fn atomic_cxchg_relaxed<T>(dst: *mut T, old: T, src: T) -> T;
61+
#[cfg(not(stage0))]
62+
pub fn atomic_cxchg_failrelaxed<T>(dst: *mut T, old: T, src: T) -> T;
63+
#[cfg(not(stage0))]
64+
pub fn atomic_cxchg_failacq<T>(dst: *mut T, old: T, src: T) -> T;
65+
#[cfg(not(stage0))]
66+
pub fn atomic_cxchg_acq_failrelaxed<T>(dst: *mut T, old: T, src: T) -> T;
67+
#[cfg(not(stage0))]
68+
pub fn atomic_cxchg_acqrel_failrelaxed<T>(dst: *mut T, old: T, src: T) -> T;
69+
70+
#[cfg(not(stage0))]
71+
pub fn atomic_cxchgweak<T>(dst: *mut T, old: T, src: T) -> (T, bool);
72+
#[cfg(not(stage0))]
73+
pub fn atomic_cxchgweak_acq<T>(dst: *mut T, old: T, src: T) -> (T, bool);
74+
#[cfg(not(stage0))]
75+
pub fn atomic_cxchgweak_rel<T>(dst: *mut T, old: T, src: T) -> (T, bool);
76+
#[cfg(not(stage0))]
77+
pub fn atomic_cxchgweak_acqrel<T>(dst: *mut T, old: T, src: T) -> (T, bool);
78+
#[cfg(not(stage0))]
79+
pub fn atomic_cxchgweak_relaxed<T>(dst: *mut T, old: T, src: T) -> (T, bool);
80+
#[cfg(not(stage0))]
81+
pub fn atomic_cxchgweak_failrelaxed<T>(dst: *mut T, old: T, src: T) -> (T, bool);
82+
#[cfg(not(stage0))]
83+
pub fn atomic_cxchgweak_failacq<T>(dst: *mut T, old: T, src: T) -> (T, bool);
84+
#[cfg(not(stage0))]
85+
pub fn atomic_cxchgweak_acq_failrelaxed<T>(dst: *mut T, old: T, src: T) -> (T, bool);
86+
#[cfg(not(stage0))]
87+
pub fn atomic_cxchgweak_acqrel_failrelaxed<T>(dst: *mut T, old: T, src: T) -> (T, bool);
6188

6289
pub fn atomic_load<T>(src: *const T) -> T;
6390
pub fn atomic_load_acq<T>(src: *const T) -> T;
@@ -559,8 +586,5 @@ extern "rust-intrinsic" {
559586
/// platforms this is a `*mut *mut T` which is filled in by the compiler and
560587
/// on MSVC it's `*mut [usize; 2]`. For more information see the compiler's
561588
/// source as well as std's catch implementation.
562-
#[cfg(not(stage0))]
563589
pub fn try(f: fn(*mut u8), data: *mut u8, local_ptr: *mut u8) -> i32;
564-
#[cfg(stage0)]
565-
pub fn try(f: fn(*mut u8), data: *mut u8) -> *mut u8;
566590
}

branches/stable/src/libcore/iter.rs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1428,7 +1428,7 @@ pub trait Iterator {
14281428
/// assert_eq!(6, doubled[2]);
14291429
/// ```
14301430
///
1431-
/// Using the 'turbofish' instead of annotationg `doubled`:
1431+
/// Using the 'turbofish' instead of annotating `doubled`:
14321432
///
14331433
/// ```
14341434
/// let a = [1, 2, 3];
@@ -1610,7 +1610,7 @@ pub trait Iterator {
16101610
/// `true`, then so does `all()`. If any of them return `false`, it
16111611
/// returns `false`.
16121612
///
1613-
/// `all()` is short-circuting; in other words, it will stop processing
1613+
/// `all()` is short-circuiting; in other words, it will stop processing
16141614
/// as soon as it finds a `false`, given that no matter what else happens,
16151615
/// the result will also be `false`.
16161616
///
@@ -1660,7 +1660,7 @@ pub trait Iterator {
16601660
/// `true`, then so does `any()`. If they all return `false`, it
16611661
/// returns `false`.
16621662
///
1663-
/// `any()` is short-circuting; in other words, it will stop processing
1663+
/// `any()` is short-circuiting; in other words, it will stop processing
16641664
/// as soon as it finds a `true`, given that no matter what else happens,
16651665
/// the result will also be `true`.
16661666
///
@@ -1711,7 +1711,7 @@ pub trait Iterator {
17111711
/// `true`, then `find()` returns `Some(element)`. If they all return
17121712
/// `false`, it returns `None`.
17131713
///
1714-
/// `find()` is short-circuting; in other words, it will stop processing
1714+
/// `find()` is short-circuiting; in other words, it will stop processing
17151715
/// as soon as the closure returns `true`.
17161716
///
17171717
/// Because `find()` takes a reference, and many iterators iterate over
@@ -1762,7 +1762,7 @@ pub trait Iterator {
17621762
/// returns `true`, then `position()` returns `Some(index)`. If all of
17631763
/// them return `false`, it returns `None`.
17641764
///
1765-
/// `position()` is short-circuting; in other words, it will stop
1765+
/// `position()` is short-circuiting; in other words, it will stop
17661766
/// processing as soon as it finds a `true`.
17671767
///
17681768
/// # Overflow Behavior
@@ -1824,7 +1824,7 @@ pub trait Iterator {
18241824
/// and if one of them returns `true`, then `rposition()` returns
18251825
/// `Some(index)`. If all of them return `false`, it returns `None`.
18261826
///
1827-
/// `rposition()` is short-circuting; in other words, it will stop
1827+
/// `rposition()` is short-circuiting; in other words, it will stop
18281828
/// processing as soon as it finds a `true`.
18291829
///
18301830
/// # Examples
@@ -2079,7 +2079,7 @@ pub trait Iterator {
20792079
(ts, us)
20802080
}
20812081

2082-
/// Creates an iterator which clone()s all of its elements.
2082+
/// Creates an iterator which `clone()`s all of its elements.
20832083
///
20842084
/// This is useful when you have an iterator over `&T`, but you need an
20852085
/// iterator over `T`.

branches/stable/src/libcore/option.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ pub enum Option<T> {
169169
None,
170170
/// Some value `T`
171171
#[stable(feature = "rust1", since = "1.0.0")]
172-
Some(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] T)
172+
Some(#[stable(feature = "rust1", since = "1.0.0")] T)
173173
}
174174

175175
/////////////////////////////////////////////////////////////////////////////

branches/stable/src/libcore/result.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -250,11 +250,11 @@ use option::Option::{self, None, Some};
250250
pub enum Result<T, E> {
251251
/// Contains the success value
252252
#[stable(feature = "rust1", since = "1.0.0")]
253-
Ok(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] T),
253+
Ok(#[stable(feature = "rust1", since = "1.0.0")] T),
254254

255255
/// Contains the error value
256256
#[stable(feature = "rust1", since = "1.0.0")]
257-
Err(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] E)
257+
Err(#[stable(feature = "rust1", since = "1.0.0")] E)
258258
}
259259

260260
/////////////////////////////////////////////////////////////////////////////

0 commit comments

Comments
 (0)