Skip to content

Commit 939cfa2

Browse files
committed
Keep the fields of RangeInclusive unstable.
1 parent 6399d16 commit 939cfa2

File tree

7 files changed

+10
-2
lines changed

7 files changed

+10
-2
lines changed

src/liballoc/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@
123123
#![feature(on_unimplemented)]
124124
#![feature(exact_chunks)]
125125
#![feature(pointer_methods)]
126+
#![feature(inclusive_range_fields)]
126127

127128
#![cfg_attr(not(test), feature(fn_traits, placement_new_protocol, swap_with_slice, i128))]
128129
#![cfg_attr(test, feature(test, box_heap))]

src/liballoc/tests/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
#![feature(unboxed_closures)]
3030
#![feature(unicode)]
3131
#![feature(exact_chunks)]
32+
#![feature(inclusive_range_fields)]
3233

3334
extern crate alloc_system;
3435
extern crate std_unicode;

src/libcore/ops/range.rs

+4-2
Original file line numberDiff line numberDiff line change
@@ -283,6 +283,8 @@ impl<Idx: PartialOrd<Idx>> RangeTo<Idx> {
283283
/// # Examples
284284
///
285285
/// ```
286+
/// #![feature(inclusive_range_fields)]
287+
///
286288
/// assert_eq!((3..=5), std::ops::RangeInclusive { start: 3, end: 5 });
287289
/// assert_eq!(3 + 4 + 5, (3..=5).sum());
288290
///
@@ -294,10 +296,10 @@ impl<Idx: PartialOrd<Idx>> RangeTo<Idx> {
294296
#[stable(feature = "inclusive_range", since = "1.26.0")]
295297
pub struct RangeInclusive<Idx> {
296298
/// The lower bound of the range (inclusive).
297-
#[stable(feature = "inclusive_range", since = "1.26.0")]
299+
#[unstable(feature = "inclusive_range_fields", issue = "49022")]
298300
pub start: Idx,
299301
/// The upper bound of the range (inclusive).
300-
#[stable(feature = "inclusive_range", since = "1.26.0")]
302+
#[unstable(feature = "inclusive_range_fields", issue = "49022")]
301303
pub end: Idx,
302304
}
303305

src/libcore/tests/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
#![feature(exact_chunks)]
4848
#![feature(atomic_nand)]
4949
#![feature(reverse_bits)]
50+
#![feature(inclusive_range_fields)]
5051

5152
extern crate core;
5253
extern crate test;

src/librustc/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@
7575
#![feature(trusted_len)]
7676
#![feature(catch_expr)]
7777
#![feature(test)]
78+
#![feature(inclusive_range_fields)]
7879

7980
#![recursion_limit="512"]
8081

src/librustc_mir/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ Rust MIR: a lowered representation of Rust. Also: an experiment!
3939
#![feature(nonzero)]
4040
#![feature(underscore_lifetimes)]
4141
#![cfg_attr(stage0, feature(never_type))]
42+
#![feature(inclusive_range_fields)]
4243

4344
extern crate arena;
4445
#[macro_use]

src/librustc_trans/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
#![feature(slice_patterns)]
3434
#![feature(conservative_impl_trait)]
3535
#![feature(optin_builtin_traits)]
36+
#![feature(inclusive_range_fields)]
3637

3738
use rustc::dep_graph::WorkProduct;
3839
use syntax_pos::symbol::Symbol;

0 commit comments

Comments
 (0)