about summary refs log tree commit diff
path: root/src/libcore
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2017-04-29 20:38:15 +0000
committerbors <bors@rust-lang.org>2017-04-29 20:38:15 +0000
commitafa1240e57330d85a372db4e28cd8bc8fa528ccb (patch)
tree196d279b28389512c66dd2facdf615604ac51d1f /src/libcore
parentb4d3ed64ec7f6d7a9fa0530377a29520a90a451f (diff)
parent5daf557a77391f14a26038d7ab70d424cfe5b040 (diff)
downloadrust-afa1240e57330d85a372db4e28cd8bc8fa528ccb.tar.gz
rust-afa1240e57330d85a372db4e28cd8bc8fa528ccb.zip
Auto merge of #41544 - alexcrichton:bump-bootstrap, r=brson
Update stage0 bootstrap compiler

We've got a freshly minted beta compiler, let's update to use that on nightly!
This has a few other changes associated with it as well

* A bump to the rustc version number (to 1.19.0)
* Movement of the `cargo` and `rls` submodules to their "proper" location in
  `src/tools/{cargo,rls}`. Now that Cargo workspaces support the `exclude`
  option this can work.
* Updates of the `cargo` and `rls` submodules to their master branches.
* Tweak to the `src/stage0.txt` format to be more amenable for Cargo version
  numbers. On the beta channel Cargo will bootstrap from a different version
  than rustc (e.g. the version numbers are different), so we need different
  configuration for this.
* Addition of `dev` as a readable key in the `src/stage0.txt` format. If present
  then stage0 compilers are downloaded from `dev-static.rust-lang.org` instead
  of `static.rust-lang.org`. This is added to accomodate our updated release
  process with Travis and AppVeyor.
Diffstat (limited to 'src/libcore')
-rw-r--r--src/libcore/intrinsics.rs24
-rw-r--r--src/libcore/marker.rs2
-rw-r--r--src/libcore/num/mod.rs72
-rw-r--r--src/libcore/ptr.rs5
4 files changed, 1 insertions, 102 deletions
diff --git a/src/libcore/intrinsics.rs b/src/libcore/intrinsics.rs
index b0287631585..9f1870e56d3 100644
--- a/src/libcore/intrinsics.rs
+++ b/src/libcore/intrinsics.rs
@@ -46,7 +46,6 @@
             issue = "0")]
 #![allow(missing_docs)]
 
-#[cfg(not(stage0))]
 #[stable(feature = "drop_in_place", since = "1.8.0")]
 #[rustc_deprecated(reason = "no longer an intrinsic - use `ptr::drop_in_place` directly",
                    since = "1.18.0")]
@@ -645,27 +644,6 @@ extern "rust-intrinsic" {
     pub fn size_of_val<T: ?Sized>(_: &T) -> usize;
     pub fn min_align_of_val<T: ?Sized>(_: &T) -> usize;
 
-    #[cfg(stage0)]
-    /// Executes the destructor (if any) of the pointed-to value.
-    ///
-    /// This has two use cases:
-    ///
-    /// * It is *required* to use `drop_in_place` to drop unsized types like
-    ///   trait objects, because they can't be read out onto the stack and
-    ///   dropped normally.
-    ///
-    /// * It is friendlier to the optimizer to do this over `ptr::read` when
-    ///   dropping manually allocated memory (e.g. when writing Box/Rc/Vec),
-    ///   as the compiler doesn't need to prove that it's sound to elide the
-    ///   copy.
-    ///
-    /// # Undefined Behavior
-    ///
-    /// This has all the same safety problems as `ptr::read` with respect to
-    /// invalid pointers, types, and double drops.
-    #[stable(feature = "drop_in_place", since = "1.8.0")]
-    pub fn drop_in_place<T: ?Sized>(to_drop: *mut T);
-
     /// Gets a static string slice containing the name of a type.
     pub fn type_name<T: ?Sized>() -> &'static str;
 
@@ -1261,11 +1239,9 @@ extern "rust-intrinsic" {
 
     /// Performs an unchecked left shift, resulting in undefined behavior when
     /// y < 0 or y >= N, where N is the width of T in bits.
-    #[cfg(not(stage0))]
     pub fn unchecked_shl<T>(x: T, y: T) -> T;
     /// Performs an unchecked right shift, resulting in undefined behavior when
     /// y < 0 or y >= N, where N is the width of T in bits.
-    #[cfg(not(stage0))]
     pub fn unchecked_shr<T>(x: T, y: T) -> T;
 
     /// Returns (a + b) mod 2<sup>N</sup>, where N is the width of T in bits.
diff --git a/src/libcore/marker.rs b/src/libcore/marker.rs
index c0aa650a1e8..3f32db12235 100644
--- a/src/libcore/marker.rs
+++ b/src/libcore/marker.rs
@@ -559,7 +559,7 @@ mod impls {
 /// any `UnsafeCell` internally, but not through an indirection.
 /// This affects, for example, whether a `static` of that type is
 /// placed in read-only static memory or writable static memory.
-#[cfg_attr(not(stage0), lang = "freeze")]
+#[lang = "freeze"]
 unsafe trait Freeze {}
 
 unsafe impl Freeze for .. {}
diff --git a/src/libcore/num/mod.rs b/src/libcore/num/mod.rs
index 5c4a43fbd11..18e2c1d5c73 100644
--- a/src/libcore/num/mod.rs
+++ b/src/libcore/num/mod.rs
@@ -778,21 +778,12 @@ macro_rules! int_impl {
         /// ```
         #[stable(feature = "num_wrapping", since = "1.2.0")]
         #[inline(always)]
-        #[cfg(not(stage0))]
         pub fn wrapping_shl(self, rhs: u32) -> Self {
             unsafe {
                 intrinsics::unchecked_shl(self, (rhs & ($BITS - 1)) as $SelfT)
             }
         }
 
-        /// Stage 0
-        #[stable(feature = "num_wrapping", since = "1.2.0")]
-        #[inline(always)]
-        #[cfg(stage0)]
-        pub fn wrapping_shl(self, rhs: u32) -> Self {
-            self.overflowing_shl(rhs).0
-        }
-
         /// Panic-free bitwise shift-right; yields `self >> mask(rhs)`,
         /// where `mask` removes any high-order bits of `rhs` that
         /// would cause the shift to exceed the bitwidth of the type.
@@ -814,21 +805,12 @@ macro_rules! int_impl {
         /// ```
         #[stable(feature = "num_wrapping", since = "1.2.0")]
         #[inline(always)]
-        #[cfg(not(stage0))]
         pub fn wrapping_shr(self, rhs: u32) -> Self {
             unsafe {
                 intrinsics::unchecked_shr(self, (rhs & ($BITS - 1)) as $SelfT)
             }
         }
 
-        /// Stage 0
-        #[stable(feature = "num_wrapping", since = "1.2.0")]
-        #[inline(always)]
-        #[cfg(stage0)]
-        pub fn wrapping_shr(self, rhs: u32) -> Self {
-            self.overflowing_shr(rhs).0
-        }
-
         /// Wrapping (modular) absolute value. Computes `self.abs()`,
         /// wrapping around at the boundary of the type.
         ///
@@ -1039,19 +1021,10 @@ macro_rules! int_impl {
         /// ```
         #[inline]
         #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(not(stage0))]
         pub fn overflowing_shl(self, rhs: u32) -> (Self, bool) {
             (self.wrapping_shl(rhs), (rhs > ($BITS - 1)))
         }
 
-        /// Stage 0
-        #[inline]
-        #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(stage0)]
-        pub fn overflowing_shl(self, rhs: u32) -> (Self, bool) {
-            (self << (rhs & ($BITS - 1)), (rhs > ($BITS - 1)))
-        }
-
         /// Shifts self right by `rhs` bits.
         ///
         /// Returns a tuple of the shifted version of self along with a boolean
@@ -1070,19 +1043,10 @@ macro_rules! int_impl {
         /// ```
         #[inline]
         #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(not(stage0))]
         pub fn overflowing_shr(self, rhs: u32) -> (Self, bool) {
             (self.wrapping_shr(rhs), (rhs > ($BITS - 1)))
         }
 
-        /// Stage 0
-        #[inline]
-        #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(stage0)]
-        pub fn overflowing_shr(self, rhs: u32) -> (Self, bool) {
-            (self >> (rhs & ($BITS - 1)), (rhs > ($BITS - 1)))
-        }
-
         /// Computes the absolute value of `self`.
         ///
         /// Returns a tuple of the absolute version of self along with a
@@ -1946,21 +1910,12 @@ macro_rules! uint_impl {
         /// ```
         #[stable(feature = "num_wrapping", since = "1.2.0")]
         #[inline(always)]
-        #[cfg(not(stage0))]
         pub fn wrapping_shl(self, rhs: u32) -> Self {
             unsafe {
                 intrinsics::unchecked_shl(self, (rhs & ($BITS - 1)) as $SelfT)
             }
         }
 
-        /// Stage 0
-        #[stable(feature = "num_wrapping", since = "1.2.0")]
-        #[inline(always)]
-        #[cfg(stage0)]
-        pub fn wrapping_shl(self, rhs: u32) -> Self {
-            self.overflowing_shl(rhs).0
-        }
-
         /// Panic-free bitwise shift-right; yields `self >> mask(rhs)`,
         /// where `mask` removes any high-order bits of `rhs` that
         /// would cause the shift to exceed the bitwidth of the type.
@@ -1982,21 +1937,12 @@ macro_rules! uint_impl {
         /// ```
         #[stable(feature = "num_wrapping", since = "1.2.0")]
         #[inline(always)]
-        #[cfg(not(stage0))]
         pub fn wrapping_shr(self, rhs: u32) -> Self {
             unsafe {
                 intrinsics::unchecked_shr(self, (rhs & ($BITS - 1)) as $SelfT)
             }
         }
 
-        /// Stage 0
-        #[stable(feature = "num_wrapping", since = "1.2.0")]
-        #[inline(always)]
-        #[cfg(stage0)]
-        pub fn wrapping_shr(self, rhs: u32) -> Self {
-            self.overflowing_shr(rhs).0
-        }
-
         /// Calculates `self` + `rhs`
         ///
         /// Returns a tuple of the addition along with a boolean indicating
@@ -2160,19 +2106,10 @@ macro_rules! uint_impl {
         /// ```
         #[inline]
         #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(not(stage0))]
         pub fn overflowing_shl(self, rhs: u32) -> (Self, bool) {
             (self.wrapping_shl(rhs), (rhs > ($BITS - 1)))
         }
 
-        /// Stage 0
-        #[inline]
-        #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(stage0)]
-        pub fn overflowing_shl(self, rhs: u32) -> (Self, bool) {
-            (self << (rhs & ($BITS - 1)), (rhs > ($BITS - 1)))
-        }
-
         /// Shifts self right by `rhs` bits.
         ///
         /// Returns a tuple of the shifted version of self along with a boolean
@@ -2191,20 +2128,11 @@ macro_rules! uint_impl {
         /// ```
         #[inline]
         #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(not(stage0))]
         pub fn overflowing_shr(self, rhs: u32) -> (Self, bool) {
             (self.wrapping_shr(rhs), (rhs > ($BITS - 1)))
 
         }
 
-        /// Stage 0
-        #[inline]
-        #[stable(feature = "wrapping", since = "1.7.0")]
-        #[cfg(stage0)]
-        pub fn overflowing_shr(self, rhs: u32) -> (Self, bool) {
-            (self >> (rhs & ($BITS - 1)), (rhs > ($BITS - 1)))
-        }
-
         /// Raises self to the power of `exp`, using exponentiation by squaring.
         ///
         /// # Examples
diff --git a/src/libcore/ptr.rs b/src/libcore/ptr.rs
index 04480fc5d31..115326bb916 100644
--- a/src/libcore/ptr.rs
+++ b/src/libcore/ptr.rs
@@ -37,11 +37,6 @@ pub use intrinsics::copy;
 #[stable(feature = "rust1", since = "1.0.0")]
 pub use intrinsics::write_bytes;
 
-#[cfg(stage0)]
-#[stable(feature = "drop_in_place", since = "1.8.0")]
-pub use intrinsics::drop_in_place;
-
-#[cfg(not(stage0))]
 /// Executes the destructor (if any) of the pointed-to value.
 ///
 /// This has two use cases: