Skip to content

Commit fedd91f

Browse files
committed
---
yaml --- r: 212980 b: refs/heads/master c: c14d86f h: refs/heads/master v: v3
1 parent e8a8105 commit fedd91f

Some content is hidden

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

99 files changed

+648
-899
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: f4518127636e6bffab0599ab4dad785a873c5bd8
2+
refs/heads/master: c14d86fd3ff3ba2d01a6e859290b30e74081313b
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: ba0e1cd8147d452c356aacb29fb87568ca26f111
55
refs/heads/try: 1864973ae17213c5a58c4dd3f9af6d1b6c7d2e05

trunk/src/doc/reference.md

Lines changed: 8 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -944,20 +944,9 @@ fn foo<T>(x: T) where T: Debug {
944944
```
945945

946946
When a generic function is referenced, its type is instantiated based on the
947-
context of the reference. For example, calling the `foo` function here:
948-
949-
```
950-
use std::fmt::Debug;
951-
952-
fn foo<T>(x: &[T]) where T: Debug {
953-
// details elided
954-
# ()
955-
}
956-
957-
foo(&[1, 2]);
958-
```
959-
960-
will instantiate type parameter `T` with `i32`.
947+
context of the reference. For example, calling the `iter` function defined
948+
above on `[1, 2]` will instantiate type parameter `T` with `i32`, and require
949+
the closure parameter to have type `Fn(i32)`.
961950

962951
The type parameters can also be explicitly supplied in a trailing
963952
[path](#paths) component after the function name. This might be necessary if
@@ -2779,24 +2768,22 @@ meaning of the operators on standard types is given here.
27792768
Like the [arithmetic operators](#arithmetic-operators), bitwise operators are
27802769
syntactic sugar for calls to methods of built-in traits. This means that
27812770
bitwise operators can be overridden for user-defined types. The default
2782-
meaning of the operators on standard types is given here. Bitwise `&`, `|` and
2783-
`^` applied to boolean arguments are equivalent to logical `&&`, `||` and `!=`
2784-
evaluated in non-lazy fashion.
2771+
meaning of the operators on standard types is given here.
27852772

27862773
* `&`
2787-
: Bitwise AND.
2774+
: And.
27882775
Calls the `bitand` method of the `std::ops::BitAnd` trait.
27892776
* `|`
2790-
: Bitwise inclusive OR.
2777+
: Inclusive or.
27912778
Calls the `bitor` method of the `std::ops::BitOr` trait.
27922779
* `^`
2793-
: Bitwise exclusive OR.
2780+
: Exclusive or.
27942781
Calls the `bitxor` method of the `std::ops::BitXor` trait.
27952782
* `<<`
27962783
: Left shift.
27972784
Calls the `shl` method of the `std::ops::Shl` trait.
27982785
* `>>`
2799-
: Right shift (arithmetic).
2786+
: Right shift.
28002787
Calls the `shr` method of the `std::ops::Shr` trait.
28012788

28022789
#### Lazy boolean operators

trunk/src/doc/trpl/traits.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,7 @@ fn normal<T: ConvertTo<i64>>(x: &T) -> i64 {
332332
fn inverse<T>() -> T
333333
// this is using ConvertTo as if it were "ConvertFrom<i32>"
334334
where i32: ConvertTo<T> {
335-
42.convert()
335+
1i32.convert()
336336
}
337337
```
338338

trunk/src/liballoc/boxed.rs

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010

1111
//! A pointer type for heap allocation.
1212
//!
13-
//! `Box<T>`, casually referred to as a 'box', provides the simplest form of heap allocation in
14-
//! Rust. Boxes provide ownership for this allocation, and drop their contents when they go out of
15-
//! scope.
13+
//! `Box<T>`, casually referred to as a 'box', provides the simplest form of
14+
//! heap allocation in Rust. Boxes provide ownership for this allocation, and
15+
//! drop their contents when they go out of scope.
1616
//!
1717
//! # Examples
1818
//!
@@ -39,15 +39,17 @@
3939
//!
4040
//! This will print `Cons(1, Cons(2, Nil))`.
4141
//!
42-
//! Recursive structures must be boxed, because if the definition of `Cons` looked like this:
42+
//! Recursive structures must be boxed, because if the definition of `Cons`
43+
//! looked like this:
4344
//!
4445
//! ```rust,ignore
4546
//! Cons(T, List<T>),
4647
//! ```
4748
//!
48-
//! It wouldn't work. This is because the size of a `List` depends on how many elements are in the
49-
//! list, and so we don't know how much memory to allocate for a `Cons`. By introducing a `Box`,
50-
//! which has a defined size, we know how big `Cons` needs to be.
49+
//! It wouldn't work. This is because the size of a `List` depends on how many
50+
//! elements are in the list, and so we don't know how much memory to allocate
51+
//! for a `Cons`. By introducing a `Box`, which has a defined size, we know how
52+
//! big `Cons` needs to be.
5153
5254
#![stable(feature = "rust1", since = "1.0.0")]
5355

@@ -355,7 +357,7 @@ impl<I: ExactSizeIterator + ?Sized> ExactSizeIterator for Box<I> {}
355357
/// }
356358
/// ```
357359
#[rustc_paren_sugar]
358-
#[unstable(feature = "core", reason = "Newly introduced")]
360+
#[unstable(feature = "fnbox", reason = "Newly introduced")]
359361
pub trait FnBox<A> {
360362
type Output;
361363

trunk/src/liballoc/lib.rs

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,26 +60,32 @@
6060
#![cfg_attr(stage0, feature(custom_attribute))]
6161
#![crate_name = "alloc"]
6262
#![unstable(feature = "alloc")]
63-
#![feature(staged_api)]
6463
#![staged_api]
6564
#![crate_type = "rlib"]
6665
#![doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png",
6766
html_favicon_url = "https://doc.rust-lang.org/favicon.ico",
68-
html_root_url = "http://doc.rust-lang.org/nightly/")]
69-
#![doc(test(no_crate_inject))]
70-
71-
#![feature(no_std)]
67+
html_root_url = "http://doc.rust-lang.org/nightly/",
68+
test(no_crate_inject))]
7269
#![no_std]
70+
7371
#![feature(allocator)]
72+
#![feature(box_syntax)]
73+
#![feature(coerce_unsized)]
74+
#![feature(core)]
75+
#![feature(core_intrinsics)]
76+
#![feature(core_prelude)]
7477
#![feature(custom_attribute)]
7578
#![feature(fundamental)]
7679
#![feature(lang_items)]
77-
#![feature(box_syntax)]
80+
#![feature(no_std)]
81+
#![feature(nonzero)]
7882
#![feature(optin_builtin_traits)]
83+
#![feature(raw)]
84+
#![feature(staged_api)]
7985
#![feature(unboxed_closures)]
80-
#![feature(unsafe_no_drop_flag, filling_drop)]
81-
#![feature(core)]
8286
#![feature(unique)]
87+
#![feature(unsafe_no_drop_flag, filling_drop)]
88+
#![feature(unsize)]
8389
#![cfg_attr(test, feature(test, alloc, rustc_private))]
8490
#![cfg_attr(all(not(feature = "external_funcs"), not(feature = "external_crate")),
8591
feature(libc))]

trunk/src/libarena/lib.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@
3232

3333
#![feature(alloc)]
3434
#![feature(box_syntax)]
35-
#![feature(core)]
35+
#![feature(core_intrinsics)]
36+
#![feature(ptr_as_ref)]
37+
#![feature(raw)]
3638
#![feature(staged_api)]
3739
#![feature(unboxed_closures)]
3840
#![cfg_attr(test, feature(test))]

trunk/src/libcollections/lib.rs

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,26 +21,42 @@
2121
#![doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png",
2222
html_favicon_url = "https://doc.rust-lang.org/favicon.ico",
2323
html_root_url = "http://doc.rust-lang.org/nightly/",
24-
html_playground_url = "http://play.rust-lang.org/")]
25-
#![doc(test(no_crate_inject))]
24+
html_playground_url = "http://play.rust-lang.org/",
25+
test(no_crate_inject))]
2626

2727
#![allow(trivial_casts)]
28+
#![cfg_attr(test, allow(deprecated))] // rand
29+
2830
#![feature(alloc)]
29-
#![feature(box_syntax)]
3031
#![feature(box_patterns)]
32+
#![feature(box_syntax)]
33+
#![feature(copy_lifetime)]
3134
#![feature(core)]
35+
#![feature(core_intrinsics)]
36+
#![feature(core_prelude)]
37+
#![feature(core_slice_ext)]
38+
#![feature(core_str_ext)]
39+
#![feature(iter_cmp)]
40+
#![feature(iter_idx)]
41+
#![feature(iter_order)]
42+
#![feature(iter_product)]
43+
#![feature(iter_sum)]
3244
#![feature(lang_items)]
45+
#![feature(num_bits_bytes)]
46+
#![feature(pattern)]
47+
#![feature(ptr_as_ref)]
48+
#![feature(raw)]
49+
#![feature(slice_patterns)]
3350
#![feature(staged_api)]
51+
#![feature(step_by)]
52+
#![feature(str_char)]
53+
#![feature(str_internals)]
3454
#![feature(unboxed_closures)]
3555
#![feature(unicode)]
3656
#![feature(unique)]
3757
#![feature(unsafe_no_drop_flag, filling_drop)]
38-
#![feature(step_by)]
39-
#![feature(str_char)]
40-
#![feature(slice_patterns)]
4158
#![feature(utf8_error)]
4259
#![cfg_attr(test, feature(rand, test))]
43-
#![cfg_attr(test, allow(deprecated))] // rand
4460
#![cfg_attr(not(test), feature(str_words))]
4561

4662
#![feature(no_std)]

trunk/src/libcore/any.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ use marker::{Reflect, Sized};
9292
#[stable(feature = "rust1", since = "1.0.0")]
9393
pub trait Any: Reflect + 'static {
9494
/// Gets the `TypeId` of `self`.
95-
#[unstable(feature = "core",
95+
#[unstable(feature = "get_type_id",
9696
reason = "this method will likely be replaced by an associated static")]
9797
fn get_type_id(&self) -> TypeId;
9898
}

trunk/src/libcore/array.rs

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,10 @@
1212
//! up to a certain length. Eventually we should able to generalize
1313
//! to all lengths.
1414
15-
#![unstable(feature = "core")] // not yet reviewed
16-
1715
#![doc(primitive = "array")]
16+
#![unstable(feature = "fixed_size_array",
17+
reason = "traits and impls are better expressed through generic \
18+
integer constants")]
1819

1920
use clone::Clone;
2021
use cmp::{PartialEq, Eq, PartialOrd, Ord, Ordering};
@@ -30,7 +31,6 @@ use slice::{Iter, IterMut, SliceExt};
3031
///
3132
/// This trait can be used to implement other traits on fixed-size arrays
3233
/// without causing much metadata bloat.
33-
#[unstable(feature = "core")]
3434
pub trait FixedSizeArray<T> {
3535
/// Converts the array to immutable slice
3636
fn as_slice(&self) -> &[T];
@@ -42,7 +42,6 @@ pub trait FixedSizeArray<T> {
4242
macro_rules! array_impls {
4343
($($N:expr)+) => {
4444
$(
45-
#[unstable(feature = "core")]
4645
impl<T> FixedSizeArray<T> for [T; $N] {
4746
#[inline]
4847
fn as_slice(&self) -> &[T] {
@@ -54,17 +53,13 @@ macro_rules! array_impls {
5453
}
5554
}
5655

57-
#[unstable(feature = "array_as_ref",
58-
reason = "should ideally be implemented for all fixed-sized arrays")]
5956
impl<T> AsRef<[T]> for [T; $N] {
6057
#[inline]
6158
fn as_ref(&self) -> &[T] {
6259
&self[..]
6360
}
6461
}
6562

66-
#[unstable(feature = "array_as_ref",
67-
reason = "should ideally be implemented for all fixed-sized arrays")]
6863
impl<T> AsMut<[T]> for [T; $N] {
6964
#[inline]
7065
fn as_mut(&mut self) -> &mut [T] {

0 commit comments

Comments
 (0)