Auto merge of #44154 - alexcrichton:bump-bootstrap, r=Mark-Simulacrum

Bump to 1.22.0 and update boostrap compiler

Time to get a new nightly!
This commit is contained in:
bors
2017-09-01 16:39:31 +00:00
19 changed files with 72 additions and 271 deletions

View File

@@ -322,14 +322,12 @@
// if the user has disabled jemalloc in `./configure`).
// `force_alloc_system` is *only* intended as a workaround for local rebuilds
// with a rustc without jemalloc.
// The not(stage0+msvc) gates will only last until the next stage0 bump
#![cfg_attr(all(
not(all(stage0, target_env = "msvc")),
any(stage0, feature = "force_alloc_system")),
feature(global_allocator))]
#[cfg(all(
not(all(stage0, target_env = "msvc")),
any(stage0, feature = "force_alloc_system")))]
// FIXME(#44236) shouldn't need MSVC logic
#![cfg_attr(all(not(target_env = "msvc"),
any(stage0, feature = "force_alloc_system")),
feature(global_allocator))]
#[cfg(all(not(target_env = "msvc"),
any(stage0, feature = "force_alloc_system")))]
#[global_allocator]
static ALLOC: alloc_system::System = alloc_system::System;

View File

@@ -14,16 +14,6 @@
//! library. Each macro is available for use when linking against the standard
//! library.
#[macro_export]
// This stability attribute is totally useless.
#[stable(feature = "rust1", since = "1.0.0")]
#[cfg(stage0)]
macro_rules! __rust_unstable_column {
() => {
column!()
}
}
/// The entry point for panic of Rust threads.
///
/// This allows a program to to terminate immediately and provide feedback

View File

@@ -522,40 +522,6 @@ pub fn begin_panic_fmt(msg: &fmt::Arguments,
begin_panic(s, file_line_col)
}
// FIXME: In PR #42938, we have added the column as info passed to the panic
// handling code. For this, we want to break the ABI of begin_panic.
// This is not possible to do directly, as the stage0 compiler is hardcoded
// to emit a call to begin_panic in src/libsyntax/ext/build.rs, only
// with the file and line number being passed, but not the colum number.
// By changing the compiler source, we can only affect behaviour of higher
// stages. We need to perform the switch over two stage0 replacements, using
// a temporary function begin_panic_new while performing the switch:
// 0. Before the current switch, we told stage1 onward to emit a call
// to begin_panic_new.
// 1. Right now, stage0 calls begin_panic_new with the new ABI,
// begin_panic stops being used. We have changed begin_panic to
// the new ABI, and started to emit calls to begin_panic in higher
// stages again, this time with the new ABI.
// 2. After the second SNAP, stage0 calls begin_panic with the new ABI,
// and we can remove the temporary begin_panic_new function.
/// This is the entry point of panicking for panic!() and assert!().
#[cfg(stage0)]
#[unstable(feature = "libstd_sys_internals",
reason = "used by the panic! macro",
issue = "0")]
#[inline(never)] #[cold] // avoid code bloat at the call sites as much as possible
pub fn begin_panic_new<M: Any + Send>(msg: M, file_line_col: &(&'static str, u32, u32)) -> ! {
// Note that this should be the only allocation performed in this code path.
// Currently this means that panic!() on OOM will invoke this code path,
// but then again we're not really ready for panic on OOM anyway. If
// we do start doing this, then we should propagate this allocation to
// be performed in the parent of this thread instead of the thread that's
// panicking.
rust_panic_with_hook(Box::new(msg), file_line_col)
}
/// This is the entry point of panicking for panic!() and assert!().
#[unstable(feature = "libstd_sys_internals",
reason = "used by the panic! macro",

View File

@@ -25,8 +25,6 @@
// Reexport some of our utilities which are expected by other crates.
#[cfg(stage0)]
pub use panicking::begin_panic_new;
pub use panicking::{begin_panic, begin_panic_fmt, update_panic_count};
#[cfg(not(test))]

View File

@@ -157,7 +157,7 @@ macro_rules! thread_local {
issue = "0")]
#[macro_export]
#[allow_internal_unstable]
#[cfg_attr(not(stage0), allow_internal_unsafe)]
#[allow_internal_unsafe]
macro_rules! __thread_local_inner {
($(#[$attr:meta])* $vis:vis $name:ident, $t:ty, $init:expr) => {
$(#[$attr])* $vis static $name: $crate::thread::LocalKey<$t> = {
@@ -394,9 +394,6 @@ pub mod fast {
}
}
#[cfg(stage0)]
unsafe impl<T> ::marker::Sync for Key<T> { }
impl<T> Key<T> {
pub const fn new() -> Key<T> {
Key {