diff --git a/src/libcollections/slice.rs b/src/libcollections/slice.rs index 929c97dceb2..84613c28d72 100644 --- a/src/libcollections/slice.rs +++ b/src/libcollections/slice.rs @@ -89,8 +89,6 @@ use core::iter::MultiplicativeIterator; use core::marker::Sized; use core::mem::size_of; use core::mem; -#[cfg(stage0)] -use core::num::wrapping::WrappingOps; use core::ops::FnMut; use core::option::Option::{self, Some, None}; use core::ptr; diff --git a/src/libcollections/vec_deque.rs b/src/libcollections/vec_deque.rs index 6083f03477c..09735e585dd 100644 --- a/src/libcollections/vec_deque.rs +++ b/src/libcollections/vec_deque.rs @@ -25,8 +25,6 @@ use core::default::Default; use core::fmt; use core::iter::{self, repeat, FromIterator, IntoIterator, RandomAccessIterator}; use core::mem; -#[cfg(stage0)] -use core::num::wrapping::WrappingOps; use core::ops::{Index, IndexMut}; use core::ptr::{self, Unique}; use core::slice; diff --git a/src/libcollectionstest/lib.rs b/src/libcollectionstest/lib.rs index f03a073e274..a6340a3d7f9 100644 --- a/src/libcollectionstest/lib.rs +++ b/src/libcollectionstest/lib.rs @@ -21,6 +21,7 @@ #![feature(unicode)] #![feature(unsafe_destructor)] #![feature(into_cow)] +#![feature(convert)] #![cfg_attr(test, feature(str_char))] #[macro_use] extern crate log; diff --git a/src/libcore/intrinsics.rs b/src/libcore/intrinsics.rs index 43cf64bf3ad..0e91eafce18 100644 --- a/src/libcore/intrinsics.rs +++ b/src/libcore/intrinsics.rs @@ -197,7 +197,6 @@ extern "rust-intrinsic" { /// Rust moves to non-zeroing dynamic drop (and thus removes the /// embedded drop flags that are being established by this /// intrinsic). - #[cfg(not(stage0))] pub fn init_dropped() -> T; /// Create a value initialized to zero. diff --git a/src/libcore/marker.rs b/src/libcore/marker.rs index 3f4b39da4b3..277b98f0523 100644 --- a/src/libcore/marker.rs +++ b/src/libcore/marker.rs @@ -487,9 +487,5 @@ pub struct InvariantType; pub trait Reflect : MarkerTrait { } -#[cfg(stage0)] -impl Reflect for T { } - -#[cfg(not(stage0))] impl Reflect for .. { } diff --git a/src/libcore/mem.rs b/src/libcore/mem.rs index 98e8668239b..249beb6295c 100644 --- a/src/libcore/mem.rs +++ b/src/libcore/mem.rs @@ -173,11 +173,6 @@ pub unsafe fn zeroed() -> T { #[inline] #[unstable(feature = "filling_drop")] pub unsafe fn dropped() -> T { - #[cfg(stage0)] - #[inline(always)] - unsafe fn dropped_impl() -> T { zeroed() } - - #[cfg(not(stage0))] #[inline(always)] unsafe fn dropped_impl() -> T { intrinsics::init_dropped() } @@ -337,38 +332,32 @@ macro_rules! repeat_u8_as_u64 { // But having the sign bit set is a pain, so 0x1d is probably better. // // And of course, 0x00 brings back the old world of zero'ing on drop. -#[cfg(not(stage0))] #[unstable(feature = "filling_drop")] +#[unstable(feature = "filling_drop")] pub const POST_DROP_U8: u8 = 0x1d; -#[cfg(not(stage0))] #[unstable(feature = "filling_drop")] +#[unstable(feature = "filling_drop")] pub const POST_DROP_U32: u32 = repeat_u8_as_u32!(POST_DROP_U8); -#[cfg(not(stage0))] #[unstable(feature = "filling_drop")] +#[unstable(feature = "filling_drop")] pub const POST_DROP_U64: u64 = repeat_u8_as_u64!(POST_DROP_U8); #[cfg(target_pointer_width = "32")] -#[cfg(not(stage0))] #[unstable(feature = "filling_drop")] +#[unstable(feature = "filling_drop")] pub const POST_DROP_USIZE: usize = POST_DROP_U32 as usize; #[cfg(target_pointer_width = "64")] -#[cfg(not(stage0))] #[unstable(feature = "filling_drop")] +#[unstable(feature = "filling_drop")] pub const POST_DROP_USIZE: usize = POST_DROP_U64 as usize; -#[cfg(stage0)] #[unstable(feature = "filling_drop")] -pub const POST_DROP_U8: u8 = 0; -#[cfg(stage0)] #[unstable(feature = "filling_drop")] -pub const POST_DROP_U32: u32 = 0; -#[cfg(stage0)] #[unstable(feature = "filling_drop")] -pub const POST_DROP_U64: u64 = 0; -#[cfg(stage0)] #[unstable(feature = "filling_drop")] -pub const POST_DROP_USIZE: usize = 0; - -/// Interprets `src` as `&U`, and then reads `src` without moving the contained value. +/// Interprets `src` as `&U`, and then reads `src` without moving the contained +/// value. /// -/// This function will unsafely assume the pointer `src` is valid for `sizeof(U)` bytes by -/// transmuting `&T` to `&U` and then reading the `&U`. It will also unsafely create a copy of the -/// contained value instead of moving out of `src`. +/// This function will unsafely assume the pointer `src` is valid for +/// `sizeof(U)` bytes by transmuting `&T` to `&U` and then reading the `&U`. It +/// will also unsafely create a copy of the contained value instead of moving +/// out of `src`. /// -/// It is not a compile-time error if `T` and `U` have different sizes, but it is highly encouraged -/// to only invoke this function where `T` and `U` have the same size. This function triggers -/// undefined behavior if `U` is larger than `T`. +/// It is not a compile-time error if `T` and `U` have different sizes, but it +/// is highly encouraged to only invoke this function where `T` and `U` have the +/// same size. This function triggers undefined behavior if `U` is larger than +/// `T`. /// /// # Examples /// diff --git a/src/librand/lib.rs b/src/librand/lib.rs index d859f1c109e..15d3d981eb5 100644 --- a/src/librand/lib.rs +++ b/src/librand/lib.rs @@ -154,7 +154,7 @@ pub trait Rng : Sized { /// /// let mut v = [0; 13579]; /// thread_rng().fill_bytes(&mut v); - /// println!("{:?}", v); + /// println!("{:?}", &v[..]); /// ``` fn fill_bytes(&mut self, dest: &mut [u8]) { // this could, in theory, be done by transmuting dest to a diff --git a/src/librustc/middle/ty.rs b/src/librustc/middle/ty.rs index 161fae11ea6..1090ba984ee 100644 --- a/src/librustc/middle/ty.rs +++ b/src/librustc/middle/ty.rs @@ -73,6 +73,7 @@ use std::cmp; use std::fmt; use std::hash::{Hash, SipHasher, Hasher}; use std::mem; +use std::num::ToPrimitive; use std::ops; use std::rc::Rc; use std::vec::IntoIter; diff --git a/src/libstd/old_io/mem.rs b/src/libstd/old_io/mem.rs index 7d491c8e8fe..c28ad651f80 100644 --- a/src/libstd/old_io/mem.rs +++ b/src/libstd/old_io/mem.rs @@ -744,7 +744,7 @@ mod test { wr.write(&[5; 10]).unwrap(); } } - assert_eq!(buf.as_ref(), [5; 100].as_ref()); + assert_eq!(&buf[..], &[5; 100][..]); }); } diff --git a/src/libstd/old_io/net/ip.rs b/src/libstd/old_io/net/ip.rs index d405bde19cb..099fe657f26 100644 --- a/src/libstd/old_io/net/ip.rs +++ b/src/libstd/old_io/net/ip.rs @@ -414,7 +414,7 @@ pub struct ParseError; /// Some examples: /// /// ```rust,no_run -/// # #![feature(old_io, core)] +/// # #![feature(old_io, core, convert)] /// # #![allow(unused_must_use)] /// /// use std::old_io::{TcpStream, TcpListener}; diff --git a/src/libstd/old_io/process.rs b/src/libstd/old_io/process.rs index a2129fcde58..84d8fa31ba8 100644 --- a/src/libstd/old_io/process.rs +++ b/src/libstd/old_io/process.rs @@ -367,7 +367,7 @@ impl Command { /// # Examples /// /// ``` - /// # #![feature(old_io, core)] + /// # #![feature(old_io, core, convert)] /// use std::old_io::Command; /// /// let output = match Command::new("cat").arg("foot.txt").output() { diff --git a/src/libsyntax/feature_gate.rs b/src/libsyntax/feature_gate.rs index 1b03a180720..98ffc054394 100644 --- a/src/libsyntax/feature_gate.rs +++ b/src/libsyntax/feature_gate.rs @@ -92,7 +92,7 @@ const KNOWN_FEATURES: &'static [(&'static str, &'static str, Status)] = &[ ("main", "1.0.0", Active), // Deprecate after snapshot - // SNAP a923278 + // SNAP 5520801 ("unsafe_destructor", "1.0.0", Active), // A temporary feature gate used to enable parser extensions needed diff --git a/src/snapshots.txt b/src/snapshots.txt index 8b05f7c8955..74d8b222c54 100644 --- a/src/snapshots.txt +++ b/src/snapshots.txt @@ -1,3 +1,13 @@ +S 2015-03-27 5520801 + bitrig-x86_64 41de2c7a69a1ac648d3fa3b65e96a29bdc122163 + freebsd-x86_64 0910bbad35e213f679d0433884fd51398eb3bc8d + linux-i386 1ef82402ed16f5a6d2f87a9a62eaa83170e249ec + linux-x86_64 ef2154372e97a3cb687897d027fd51c8f2c5f349 + macos-i386 0310b1a970f2da7e61770fd14dbbbdca3b518234 + macos-x86_64 5f35d9c920b8083a7420ef8cf5b00d5ef3085dfa + winnt-i386 808b7961f85872f04ec15ad0d3e9e23ae9bc0c3b + winnt-x86_64 903a99a58f57a9bd9848cc68a2445dda881f1ee8 + S 2015-03-25 a923278 bitrig-x86_64 41de2c7a69a1ac648d3fa3b65e96a29bdc122163 freebsd-x86_64 cd02c86a9218da73b2a45aff293787010d33bf3e