Skip to content

Commit a833337

Browse files
committed
auto merge of #21288 : brson/rust/snaps, r=alexcrichton
This fixes the issues mentioned in #21236, as well as the one #21230 where `CFG_BOOTSTRAP_KEY` was being set to simply 'N'. It changes the build such that `RUSTC_BOOTSTRAP_KEY` is only exported on -beta and -stable, so that the behavior of the -dev, -nightly, and snapshot compilers is the same everywhere. Haven't run it completely through 'make check' yet, but the I have verified that the aforementioned issues are fixed. r? @alexcrichton cc @eddyb
2 parents 6da8827 + 8b2335a commit a833337

File tree

75 files changed

+218
-479
lines changed

Some content is hidden

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

75 files changed

+218
-479
lines changed

Diff for: configure

+1-1
Original file line numberDiff line numberDiff line change
@@ -612,7 +612,7 @@ putvar CFG_RELEASE_CHANNEL
612612
# channel.
613613
# Basing CFG_BOOTSTRAP_KEY on CFG_BOOTSTRAP_KEY lets it get picked up
614614
# during a Makefile reconfig.
615-
CFG_BOOTSTRAP_KEY="${CFG_BOOTSTRAP_KEY-`date +%N`}"
615+
CFG_BOOTSTRAP_KEY="${CFG_BOOTSTRAP_KEY-`date +%H:%M:%S`}"
616616
putvar CFG_BOOTSTRAP_KEY
617617

618618
step_msg "looking for build programs"

Diff for: mk/main.mk

+2-2
Original file line numberDiff line numberDiff line change
@@ -330,10 +330,10 @@ ifdef CFG_DISABLE_UNSTABLE_FEATURES
330330
CFG_INFO := $(info cfg: disabling unstable features (CFG_DISABLE_UNSTABLE_FEATURES))
331331
# Turn on feature-staging
332332
export CFG_DISABLE_UNSTABLE_FEATURES
333-
endif
334333
# Subvert unstable feature lints to do the self-build
335-
export CFG_BOOTSTRAP_KEY
336334
export RUSTC_BOOTSTRAP_KEY:=$(CFG_BOOTSTRAP_KEY)
335+
endif
336+
export CFG_BOOTSTRAP_KEY
337337

338338
######################################################################
339339
# Per-stage targets and runner

Diff for: src/compiletest/compiletest.rs

+1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
#![feature(slicing_syntax, unboxed_closures)]
1414
#![feature(box_syntax)]
1515
#![feature(int_uint)]
16+
#![allow(unstable)]
1617

1718
#![deny(warnings)]
1819

Diff for: src/driver/driver.rs

+2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11+
#![allow(unstable)]
12+
1113
#[cfg(rustdoc)]
1214
extern crate "rustdoc" as this;
1315

Diff for: src/liballoc/boxed.rs

-8
Original file line numberDiff line numberDiff line change
@@ -117,14 +117,6 @@ impl<T: ?Sized + Ord> Ord for Box<T> {
117117
#[stable]
118118
impl<T: ?Sized + Eq> Eq for Box<T> {}
119119

120-
#[cfg(stage0)]
121-
impl<S: hash::Writer, T: ?Sized + Hash<S>> Hash<S> for Box<T> {
122-
#[inline]
123-
fn hash(&self, state: &mut S) {
124-
(**self).hash(state);
125-
}
126-
}
127-
#[cfg(not(stage0))]
128120
impl<S: hash::Hasher, T: ?Sized + Hash<S>> Hash<S> for Box<T> {
129121
#[inline]
130122
fn hash(&self, state: &mut S) {

Diff for: src/liballoc/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@
6666

6767
#![no_std]
6868
#![allow(unknown_features)]
69+
#![allow(unstable)]
6970
#![feature(lang_items, unsafe_destructor)]
7071
#![feature(box_syntax)]
7172
#![feature(optin_builtin_traits)]

Diff for: src/liballoc/rc.rs

-8
Original file line numberDiff line numberDiff line change
@@ -686,14 +686,6 @@ impl<T: Ord> Ord for Rc<T> {
686686
}
687687

688688
// FIXME (#18248) Make `T` `Sized?`
689-
#[cfg(stage0)]
690-
impl<S: hash::Writer, T: Hash<S>> Hash<S> for Rc<T> {
691-
#[inline]
692-
fn hash(&self, state: &mut S) {
693-
(**self).hash(state);
694-
}
695-
}
696-
#[cfg(not(stage0))]
697689
impl<S: hash::Hasher, T: Hash<S>> Hash<S> for Rc<T> {
698690
#[inline]
699691
fn hash(&self, state: &mut S) {

Diff for: src/libarena/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
#![feature(box_syntax)]
3535
#![allow(unknown_features)] #![feature(int_uint)]
3636
#![allow(missing_docs)]
37+
#![allow(unstable)]
3738

3839
extern crate alloc;
3940

Diff for: src/libcollections/btree/map.rs

-12
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ use core::cmp::Ordering;
2424
use core::default::Default;
2525
use core::fmt::Show;
2626
use core::hash::{Hash, Hasher};
27-
#[cfg(stage0)]
28-
use core::hash::Writer;
2927
use core::iter::{Map, FromIterator};
3028
use core::ops::{Index, IndexMut};
3129
use core::{iter, fmt, mem};
@@ -822,16 +820,6 @@ impl<K: Ord, V> Extend<(K, V)> for BTreeMap<K, V> {
822820
}
823821

824822
#[stable]
825-
#[cfg(stage0)]
826-
impl<S: Writer, K: Hash<S>, V: Hash<S>> Hash<S> for BTreeMap<K, V> {
827-
fn hash(&self, state: &mut S) {
828-
for elt in self.iter() {
829-
elt.hash(state);
830-
}
831-
}
832-
}
833-
#[stable]
834-
#[cfg(not(stage0))]
835823
impl<S: Hasher, K: Hash<S>, V: Hash<S>> Hash<S> for BTreeMap<K, V> {
836824
fn hash(&self, state: &mut S) {
837825
for elt in self.iter() {

Diff for: src/libcollections/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
#![feature(unboxed_closures)]
2929
#![feature(old_impl_check)]
3030
#![allow(unknown_features)] #![feature(int_uint)]
31+
#![allow(unstable)]
3132
#![no_std]
3233

3334
#[macro_use]

Diff for: src/libcollections/string.rs

-9
Original file line numberDiff line numberDiff line change
@@ -830,15 +830,6 @@ impl fmt::Show for String {
830830
}
831831

832832
#[unstable = "waiting on Hash stabilization"]
833-
#[cfg(stage0)]
834-
impl<H: hash::Writer> hash::Hash<H> for String {
835-
#[inline]
836-
fn hash(&self, hasher: &mut H) {
837-
(**self).hash(hasher)
838-
}
839-
}
840-
#[unstable = "waiting on Hash stabilization"]
841-
#[cfg(not(stage0))]
842833
impl<H: hash::Writer + hash::Hasher> hash::Hash<H> for String {
843834
#[inline]
844835
fn hash(&self, hasher: &mut H) {

Diff for: src/libcollections/vec.rs

-8
Original file line numberDiff line numberDiff line change
@@ -1222,14 +1222,6 @@ impl<T:Clone> Clone for Vec<T> {
12221222
}
12231223
}
12241224

1225-
#[cfg(stage0)]
1226-
impl<S: hash::Writer, T: Hash<S>> Hash<S> for Vec<T> {
1227-
#[inline]
1228-
fn hash(&self, state: &mut S) {
1229-
self.as_slice().hash(state);
1230-
}
1231-
}
1232-
#[cfg(not(stage0))]
12331225
impl<S: hash::Writer + hash::Hasher, T: Hash<S>> Hash<S> for Vec<T> {
12341226
#[inline]
12351227
fn hash(&self, state: &mut S) {

Diff for: src/libcore/fmt/mod.rs

-23
Original file line numberDiff line numberDiff line change
@@ -180,25 +180,6 @@ impl<'a> Arguments<'a> {
180180
/// unsafety, but will ignore invalid .
181181
#[doc(hidden)] #[inline]
182182
#[unstable = "implementation detail of the `format_args!` macro"]
183-
#[cfg(stage0)] // SNAP 9e4e524
184-
pub fn with_placeholders(pieces: &'a [&'a str],
185-
fmt: &'a [rt::Argument<'a>],
186-
args: &'a [Argument<'a>]) -> Arguments<'a> {
187-
Arguments {
188-
pieces: pieces,
189-
fmt: Some(fmt),
190-
args: args
191-
}
192-
}
193-
/// This function is used to specify nonstandard formatting parameters.
194-
/// The `pieces` array must be at least as long as `fmt` to construct
195-
/// a valid Arguments structure. Also, any `Count` within `fmt` that is
196-
/// `CountIsParam` or `CountIsNextParam` has to point to an argument
197-
/// created with `argumentuint`. However, failing to do so doesn't cause
198-
/// unsafety, but will ignore invalid .
199-
#[doc(hidden)] #[inline]
200-
#[unstable = "implementation detail of the `format_args!` macro"]
201-
#[cfg(not(stage0))]
202183
pub fn with_placeholders(pieces: &'a [&'a str],
203184
fmt: &'a [rt::Argument],
204185
args: &'a [Argument<'a>]) -> Arguments<'a> {
@@ -226,10 +207,6 @@ pub struct Arguments<'a> {
226207
pieces: &'a [&'a str],
227208

228209
// Placeholder specs, or `None` if all specs are default (as in "{}{}").
229-
// SNAP 9e4e524
230-
#[cfg(stage0)]
231-
fmt: Option<&'a [rt::Argument<'a>]>,
232-
#[cfg(not(stage0))]
233210
fmt: Option<&'a [rt::Argument]>,
234211

235212
// Dynamic arguments for interpolation, to be interleaved with string

Diff for: src/libcore/fmt/rt.rs

-9
Original file line numberDiff line numberDiff line change
@@ -21,21 +21,12 @@ pub use self::Count::*;
2121
pub use self::Position::*;
2222
pub use self::Flag::*;
2323

24-
// SNAP 9e4e524
2524
#[doc(hidden)]
2625
#[derive(Copy)]
27-
#[cfg(not(stage0))]
2826
pub struct Argument {
2927
pub position: Position,
3028
pub format: FormatSpec,
3129
}
32-
#[doc(hidden)]
33-
#[derive(Copy)]
34-
#[cfg(stage0)]
35-
pub struct Argument<'a> {
36-
pub position: Position,
37-
pub format: FormatSpec,
38-
}
3930

4031
#[doc(hidden)]
4132
#[derive(Copy)]

0 commit comments

Comments
 (0)