From 938099a7ebccbad2a2cad58d71df316d5ccd512c Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Tue, 11 Aug 2015 14:31:23 -0700 Subject: [PATCH] Register new snapshots * Lots of core prelude imports removed * Makefile support for MSVC env vars and Rust crates removed * Makefile support for morestack removed --- mk/cfg/i686-pc-windows-msvc.mk | 5 -- mk/cfg/x86_64-pc-windows-msvc.mk | 5 -- mk/main.mk | 5 -- mk/platform.mk | 61 ------------------ mk/rt.mk | 4 +- mk/target.mk | 93 +-------------------------- src/liballoc/arc.rs | 3 - src/liballoc/boxed.rs | 3 - src/liballoc/lib.rs | 3 - src/liballoc/rc.rs | 3 - src/libcollections/binary_heap.rs | 3 - src/libcollections/bit.rs | 3 - src/libcollections/btree/map.rs | 5 -- src/libcollections/btree/node.rs | 3 - src/libcollections/btree/set.rs | 3 - src/libcollections/enum_set.rs | 3 - src/libcollections/lib.rs | 3 - src/libcollections/linked_list.rs | 3 - src/libcollections/string.rs | 3 - src/libcollections/vec.rs | 3 - src/libcollections/vec_deque.rs | 3 - src/libcollections/vec_map.rs | 3 - src/libcore/lib.rs | 44 +++---------- src/liblibc/lib.rs | 2 - src/librand/chacha.rs | 3 - src/librand/distributions/mod.rs | 3 - src/librand/distributions/range.rs | 3 - src/librand/isaac.rs | 3 - src/librand/lib.rs | 6 -- src/librand/rand_impls.rs | 3 - src/librand/reseeding.rs | 3 - src/librustc_llvm/lib.rs | 4 +- src/librustc_unicode/lib.rs | 3 - src/librustc_unicode/u_str.rs | 2 - src/libstd/ffi/os_str.rs | 3 - src/libstd/fs.rs | 3 - src/libstd/io/cursor.rs | 3 - src/libstd/io/impls.rs | 3 - src/libstd/io/util.rs | 3 - src/libstd/lib.rs | 3 - src/libstd/net/udp.rs | 3 - src/libstd/num/f32.rs | 3 - src/libstd/num/f64.rs | 3 - src/libstd/num/mod.rs | 2 - src/libstd/path.rs | 9 --- src/libstd/rand/mod.rs | 3 - src/libstd/rand/os.rs | 4 -- src/libstd/rand/reader.rs | 1 - src/libstd/rt/args.rs | 4 -- src/libstd/rt/backtrace.rs | 3 - src/libstd/sync/future.rs | 2 - src/libstd/sync/mpsc/mod.rs | 3 - src/libstd/sync/mpsc/mpsc_queue.rs | 3 - src/libstd/sync/mpsc/oneshot.rs | 3 - src/libstd/sync/mpsc/select.rs | 3 - src/libstd/sync/mpsc/shared.rs | 3 - src/libstd/sync/mpsc/spsc_queue.rs | 3 - src/libstd/sync/mpsc/stream.rs | 3 - src/libstd/sync/mpsc/sync.rs | 3 - src/libstd/sync/once.rs | 3 - src/libstd/sys/common/backtrace.rs | 2 - src/libstd/sys/common/mod.rs | 7 -- src/libstd/sys/common/poison.rs | 3 - src/libstd/sys/common/thread_info.rs | 3 - src/libstd/sys/common/thread_local.rs | 3 - src/libstd/sys/common/wtf8.rs | 3 - src/libstd/sys/unix/backtrace.rs | 2 - src/libstd/sys/unix/condvar.rs | 3 - src/libstd/sys/unix/ext/fs.rs | 3 - src/libstd/sys/unix/ext/process.rs | 2 - src/libstd/sys/unix/fd.rs | 3 - src/libstd/sys/unix/fs.rs | 2 - src/libstd/sys/unix/mod.rs | 3 - src/libstd/sys/unix/mutex.rs | 3 - src/libstd/sys/unix/os_str.rs | 3 - src/libstd/sys/unix/pipe.rs | 3 - src/libstd/sys/unix/rwlock.rs | 3 - src/libstd/sys/unix/stack_overflow.rs | 3 - src/libstd/sys/unix/stdio.rs | 3 - src/libstd/sys/unix/thread.rs | 3 - src/libstd/sys/unix/thread_local.rs | 2 - src/libstd/sys/windows/backtrace.rs | 2 - src/libstd/sys/windows/condvar.rs | 3 - src/libstd/sys/windows/ext/fs.rs | 3 - src/libstd/sys/windows/fs.rs | 2 - src/libstd/sys/windows/handle.rs | 3 - src/libstd/sys/windows/net.rs | 3 - src/libstd/sys/windows/pipe.rs | 3 - src/libstd/sys/windows/rwlock.rs | 3 - src/libstd/sys/windows/thread.rs | 3 - src/libstd/thread/local.rs | 6 -- src/libstd/thread/scoped_tls.rs | 8 --- src/libstd/time/duration.rs | 3 - src/rt/empty.c | 9 --- src/snapshots.txt | 11 ++++ 95 files changed, 25 insertions(+), 483 deletions(-) delete mode 100644 src/rt/empty.c diff --git a/mk/cfg/i686-pc-windows-msvc.mk b/mk/cfg/i686-pc-windows-msvc.mk index bb1280688a7..4c8f1103734 100644 --- a/mk/cfg/i686-pc-windows-msvc.mk +++ b/mk/cfg/i686-pc-windows-msvc.mk @@ -22,8 +22,3 @@ CFG_LDPATH_i686-pc-windows-msvc := CFG_RUN_i686-pc-windows-msvc=$(2) CFG_RUN_TARG_i686-pc-windows-msvc=$(call CFG_RUN_i686-pc-windows-msvc,,$(2)) CFG_GNU_TRIPLE_i686-pc-windows-msvc := i686-pc-win32 - -# All windows nightiles are currently a GNU triple, so this MSVC triple is not -# bootstrapping from itself. This is relevant during stage0, and other parts of -# the build system take this into account. -BOOTSTRAP_FROM_i686-pc-windows-msvc := i686-pc-windows-gnu diff --git a/mk/cfg/x86_64-pc-windows-msvc.mk b/mk/cfg/x86_64-pc-windows-msvc.mk index 6f12836f056..65cf28f6852 100644 --- a/mk/cfg/x86_64-pc-windows-msvc.mk +++ b/mk/cfg/x86_64-pc-windows-msvc.mk @@ -22,8 +22,3 @@ CFG_LDPATH_x86_64-pc-windows-msvc := CFG_RUN_x86_64-pc-windows-msvc=$(2) CFG_RUN_TARG_x86_64-pc-windows-msvc=$(call CFG_RUN_x86_64-pc-windows-msvc,,$(2)) CFG_GNU_TRIPLE_x86_64-pc-windows-msvc := x86_64-pc-win32 - -# All windows nightiles are currently a GNU triple, so this MSVC triple is not -# bootstrapping from itself. This is relevant during stage0, and other parts of -# the build system take this into account. -BOOTSTRAP_FROM_x86_64-pc-windows-msvc := x86_64-pc-windows-gnu diff --git a/mk/main.mk b/mk/main.mk index a65e09e15fd..b70926388ca 100644 --- a/mk/main.mk +++ b/mk/main.mk @@ -400,11 +400,6 @@ TSREQ$(1)_T_$(2)_H_$(3) = \ $$(foreach obj,$$(INSTALLED_OBJECTS_$(2)),\ $$(TLIB$(1)_T_$(2)_H_$(3))/$$(obj)) -ifeq ($(1),0) -TSREQ$(1)_T_$(2)_H_$(3) += \ - $$(TLIB$(1)_T_$(2)_H_$(3))/$$(call CFG_STATIC_LIB_NAME_$(2),morestack) -endif - # Prerequisites for a working stageN compiler and libraries, for a specific # target SREQ$(1)_T_$(2)_H_$(3) = \ diff --git a/mk/platform.mk b/mk/platform.mk index 9a6de772ab4..fcb6a5b50d3 100644 --- a/mk/platform.mk +++ b/mk/platform.mk @@ -237,64 +237,3 @@ endef $(foreach target,$(CFG_TARGET), \ $(eval $(call CFG_MAKE_TOOLCHAIN,$(target)))) - -# There are more comments about this available in the target specification for -# Windows MSVC in the compiler, but the gist of it is that we use `llvm-ar.exe` -# instead of `lib.exe` for assembling archives, so we need to inject this custom -# dependency here. -# -# FIXME(stage0): remove this and all other relevant support in the makefiles -# after a snapshot is made -define ADD_LLVM_AR_TO_MSVC_DEPS -ifeq ($$(findstring msvc,$(1)),msvc) -NATIVE_TOOL_DEPS_core_T_$(1) += llvm-ar.exe -INSTALLED_BINS_$(1) += llvm-ar.exe -endif -endef - -$(foreach target,$(CFG_TARGET), \ - $(eval $(call ADD_LLVM_AR_TO_MSVC_DEPS,$(target)))) - -# When working with MSVC on windows, each DLL needs to explicitly declare its -# interface to the outside world through some means. The options for doing so -# include: -# -# 1. A custom attribute on each function itself -# 2. A linker argument saying what to export -# 3. A file which lists all symbols that need to be exported -# -# The Rust compiler takes care (1) for us for all Rust code by annotating all -# public-facing functions with dllexport, but we have a few native dependencies -# which need to cross the DLL boundary. The most important of these dependencies -# is LLVM which is linked into `rustc_llvm.dll` but primarily used from -# `rustc_trans.dll`. This means that many of LLVM's C API functions need to be -# exposed from `rustc_llvm.dll` to be forwarded over the boundary. -# -# Unfortunately, at this time, LLVM does not handle this sort of exportation on -# Windows for us, so we're forced to do it ourselves if we want it (which seems -# like the path of least resistance right now). To do this we generate a `.DEF` -# file [1] which we then custom-pass to the linker when building the rustc_llvm -# crate. This DEF file list all symbols that are exported from -# `src/librustc_llvm/lib.rs` and is generated by a small python script. -# -# Fun times! -# -# [1]: https://msdn.microsoft.com/en-us/library/28d6s79h.aspx -# -# FIXME(stage0): remove this macro and the usage below (and the commments above) -# when a new snapshot is available. Also remove the -# RUSTFLAGS$(1)_.._T_ variable in mk/target.mk along with -# CUSTOM_DEPS (as they were only added for this) -define ADD_RUSTC_LLVM_DEF_TO_MSVC -ifeq ($$(findstring msvc,$(1)),msvc) -RUSTFLAGS0_rustc_llvm_T_$(1) += -C link-args="-DEF:$(1)/rt/rustc_llvm.def" -CUSTOM_DEPS0_rustc_llvm_T_$(1) += $(1)/rt/rustc_llvm.def - -$(1)/rt/rustc_llvm.def: $$(S)src/etc/mklldef.py $$(S)src/librustc_llvm/lib.rs - $$(CFG_PYTHON) $$^ $$@ rustc_llvm-$$(CFG_FILENAME_EXTRA) -endif -endef - -$(foreach target,$(CFG_TARGET), \ - $(eval $(call ADD_RUSTC_LLVM_DEF_TO_MSVC,$(target)))) - diff --git a/mk/rt.mk b/mk/rt.mk index e505d78f099..b8f345699f4 100644 --- a/mk/rt.mk +++ b/mk/rt.mk @@ -35,8 +35,7 @@ # that's per-target so you're allowed to conditionally add files based on the # target. ################################################################################ -NATIVE_LIBS := rust_builtin hoedown miniz \ - rust_test_helpers morestack +NATIVE_LIBS := rust_builtin hoedown miniz rust_test_helpers # $(1) is the target triple define NATIVE_LIBRARIES @@ -54,7 +53,6 @@ NATIVE_DEPS_miniz_$(1) = miniz.c NATIVE_DEPS_rust_builtin_$(1) := rust_builtin.c \ rust_android_dummy.c NATIVE_DEPS_rust_test_helpers_$(1) := rust_test_helpers.c -NATIVE_DEPS_morestack_$(1) := empty.c ################################################################################ # You shouldn't find it that necessary to edit anything below this line. diff --git a/mk/target.mk b/mk/target.mk index 63ce003c810..aae66c45b57 100644 --- a/mk/target.mk +++ b/mk/target.mk @@ -37,10 +37,7 @@ CRATE_FULLDEPS_$(1)_T_$(2)_H_$(3)_$(4) := \ $$(foreach dep,$$(NATIVE_DEPS_$(4)), \ $$(RT_OUTPUT_DIR_$(2))/$$(call CFG_STATIC_LIB_NAME_$(2),$$(dep))) \ $$(foreach dep,$$(NATIVE_DEPS_$(4)_T_$(2)), \ - $$(RT_OUTPUT_DIR_$(2))/$$(dep)) \ - $$(foreach dep,$$(NATIVE_TOOL_DEPS_$(4)_T_$(2)), \ - $$(TBIN$(1)_T_$(3)_H_$(3))/$$(dep)) \ - $$(CUSTOM_DEPS$(1)_$(4)_T_$(2)) + $$(RT_OUTPUT_DIR_$(2))/$$(dep)) endef $(foreach host,$(CFG_HOST), \ @@ -142,9 +139,6 @@ SNAPSHOT_RUSTC_POST_CLEANUP=$(HBIN0_H_$(CFG_BUILD))/rustc$(X_$(CFG_BUILD)) define TARGET_HOST_RULES -$$(TBIN$(1)_T_$(2)_H_$(3))/: - mkdir -p $$@ - $$(TLIB$(1)_T_$(2)_H_$(3))/: mkdir -p $$@ @@ -152,11 +146,6 @@ $$(TLIB$(1)_T_$(2)_H_$(3))/%: $$(RT_OUTPUT_DIR_$(2))/% \ | $$(TLIB$(1)_T_$(2)_H_$(3))/ $$(SNAPSHOT_RUSTC_POST_CLEANUP) @$$(call E, cp: $$@) $$(Q)cp $$< $$@ - -$$(TBIN$(1)_T_$(2)_H_$(3))/%: $$(CFG_LLVM_INST_DIR_$(2))/bin/% \ - | $$(TBIN$(1)_T_$(2)_H_$(3))/ $$(SNAPSHOT_RUSTC_POST_CLEANUP) - @$$(call E, cp: $$@) - $$(Q)cp $$< $$@ endef $(foreach source,$(CFG_HOST), \ @@ -180,83 +169,3 @@ $(foreach host,$(CFG_HOST), \ $(foreach stage,$(STAGES), \ $(foreach tool,$(TOOLS), \ $(eval $(call TARGET_TOOL,$(stage),$(target),$(host),$(tool))))))) - -# We have some triples which are bootstrapped from other triples, and this means -# that we need to fixup some of the native tools that a triple depends on. -# -# For example, MSVC requires the llvm-ar.exe executable to manage archives, but -# it bootstraps from the GNU Windows triple. This means that the compiler will -# add this directory to PATH when executing new processes: -# -# $SYSROOT/rustlib/x86_64-pc-windows-gnu/bin -# -# Unfortunately, however, the GNU triple is not known about in stage0, so the -# tools are actually located in: -# -# $SYSROOT/rustlib/x86_64-pc-windows-msvc/bin -# -# To remedy this problem, the rules below copy all native tool dependencies into -# the bootstrap triple's location in stage 0 so the bootstrap compiler can find -# the right sets of tools. Later stages (1+) will have the right host triple for -# the compiler, so there's no need to worry there. -# -# $(1) - stage -# $(2) - triple that's being used as host/target -# $(3) - triple snapshot is built for -# $(4) - crate -# $(5) - tool -# -# FIXME(stage0): remove this and all other relevant support in the makefiles -# after a snapshot is made -define MOVE_TOOLS_TO_SNAPSHOT_HOST_DIR -ifneq (,$(3)) -$$(TLIB$(1)_T_$(2)_H_$(2))/stamp.$(4): $$(HLIB$(1)_H_$(2))/rustlib/$(3)/bin/$(5) - -$$(HLIB$(1)_H_$(2))/rustlib/$(3)/bin/$(5): $$(TBIN$(1)_T_$(2)_H_$(2))/$(5) - mkdir -p $$(@D) - cp $$< $$@ -endif -endef - -$(foreach target,$(CFG_TARGET), \ - $(foreach crate,$(CRATES), \ - $(foreach tool,$(NATIVE_TOOL_DEPS_$(crate)_T_$(target)), \ - $(eval $(call MOVE_TOOLS_TO_SNAPSHOT_HOST_DIR,0,$(target),$(BOOTSTRAP_FROM_$(target)),$(crate),$(tool)))))) - -# For MSVC targets we need to set up some environment variables for the linker -# to work correctly when building Rust crates. These two variables are: -# -# - LIB tells the linker the default search path for finding system libraries, -# for example kernel32.dll -# - PATH needs to be modified to ensure that MSVC's link.exe is first in the -# path instead of MinGW's /usr/bin/link.exe (entirely unrelated) -# -# The values for these variables are detected by the configure script. -# -# FIXME(stage0): remove this and all other relevant support in the makefiles -# after a snapshot is made -define SETUP_LIB_MSVC_ENV_VARS -ifeq ($$(findstring msvc,$(2)),msvc) -$$(TLIB$(1)_T_$(2)_H_$(3))/stamp.$(4): \ - export LIB := $$(CFG_MSVC_LIB_PATH_$$(HOST_$(2))) -$$(TLIB$(1)_T_$(2)_H_$(3))/stamp.$(4): \ - export PATH := $$(CFG_MSVC_BINDIR_$$(HOST_$(2))):$$(PATH) -endif -endef -define SETUP_TOOL_MSVC_ENV_VARS -ifeq ($$(findstring msvc,$(2)),msvc) -$$(TBIN$(1)_T_$(2)_H_$(3))/$(4)$$(X_$(2)): \ - export LIB := $$(CFG_MSVC_LIB_PATH_$$(HOST_$(2))) -$$(TBIN$(1)_T_$(2)_H_$(3))/$(4)$$(X_$(2)): \ - export PATH := $$(CFG_MSVC_BINDIR_$$(HOST_$(2))):$$(PATH) -endif -endef - -$(foreach host,$(CFG_HOST), \ - $(foreach target,$(CFG_TARGET), \ - $(foreach crate,$(CRATES), \ - $(eval $(call SETUP_LIB_MSVC_ENV_VARS,0,$(target),$(host),$(crate)))))) -$(foreach host,$(CFG_HOST), \ - $(foreach target,$(CFG_TARGET), \ - $(foreach tool,$(TOOLS), \ - $(eval $(call SETUP_TOOL_MSVC_ENV_VARS,0,$(target),$(host),$(tool)))))) diff --git a/src/liballoc/arc.rs b/src/liballoc/arc.rs index 56c7324090e..ccf8784e2a7 100644 --- a/src/liballoc/arc.rs +++ b/src/liballoc/arc.rs @@ -71,9 +71,6 @@ use boxed::Box; -#[cfg(stage0)] -use core::prelude::v1::*; - use core::atomic; use core::atomic::Ordering::{Relaxed, Release, Acquire, SeqCst}; use core::fmt; diff --git a/src/liballoc/boxed.rs b/src/liballoc/boxed.rs index ab1a5ba9019..f31bb60ed97 100644 --- a/src/liballoc/boxed.rs +++ b/src/liballoc/boxed.rs @@ -53,9 +53,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use heap; use raw_vec::RawVec; diff --git a/src/liballoc/lib.rs b/src/liballoc/lib.rs index 6d251cae41d..66ab35a48dc 100644 --- a/src/liballoc/lib.rs +++ b/src/liballoc/lib.rs @@ -92,7 +92,6 @@ #![feature(unsize)] #![feature(core_slice_ext)] #![feature(core_str_ext)] -#![cfg_attr(stage0, feature(core, core_prelude))] #![cfg_attr(test, feature(test, alloc, rustc_private, box_raw))] #![cfg_attr(all(not(feature = "external_funcs"), not(feature = "external_crate")), @@ -101,8 +100,6 @@ #[cfg(all(not(feature = "external_funcs"), not(feature = "external_crate")))] extern crate libc; -#[cfg(stage0)] #[macro_use] extern crate core; - // Allow testing this library #[cfg(test)] #[macro_use] extern crate std; diff --git a/src/liballoc/rc.rs b/src/liballoc/rc.rs index 05fd36e8e7f..620ceaa346b 100644 --- a/src/liballoc/rc.rs +++ b/src/liballoc/rc.rs @@ -150,9 +150,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - #[cfg(not(test))] use boxed::Box; #[cfg(test)] diff --git a/src/libcollections/binary_heap.rs b/src/libcollections/binary_heap.rs index 65a252aea49..c46025b3335 100644 --- a/src/libcollections/binary_heap.rs +++ b/src/libcollections/binary_heap.rs @@ -151,9 +151,6 @@ #![allow(missing_docs)] #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use core::iter::{FromIterator}; use core::mem::swap; use core::ptr; diff --git a/src/libcollections/bit.rs b/src/libcollections/bit.rs index af33181c5d0..e1ae4c51e3a 100644 --- a/src/libcollections/bit.rs +++ b/src/libcollections/bit.rs @@ -86,9 +86,6 @@ //! println!("There are {} primes below {}", num_primes, max_prime); //! ``` -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp::Ordering; use core::cmp; use core::fmt; diff --git a/src/libcollections/btree/map.rs b/src/libcollections/btree/map.rs index f5d1d44b404..a5c6ebaa5ae 100644 --- a/src/libcollections/btree/map.rs +++ b/src/libcollections/btree/map.rs @@ -17,9 +17,6 @@ use self::Entry::*; -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp::Ordering; use core::fmt::Debug; use core::hash::{Hash, Hasher}; @@ -531,8 +528,6 @@ enum Continuation { /// to nodes. By using this module much better safety guarantees can be made, and more search /// boilerplate gets cut out. mod stack { - #[cfg(stage0)] - use core::prelude::v1::*; use core::marker; use core::mem; use core::ops::{Deref, DerefMut}; diff --git a/src/libcollections/btree/node.rs b/src/libcollections/btree/node.rs index e0018efe9e0..7b544078d5b 100644 --- a/src/libcollections/btree/node.rs +++ b/src/libcollections/btree/node.rs @@ -16,9 +16,6 @@ pub use self::SearchResult::*; pub use self::ForceResult::*; pub use self::TraversalItem::*; -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp::Ordering::{Greater, Less, Equal}; use core::intrinsics::arith_offset; use core::iter::Zip; diff --git a/src/libcollections/btree/set.rs b/src/libcollections/btree/set.rs index e31147b7308..3f545e7b2a1 100644 --- a/src/libcollections/btree/set.rs +++ b/src/libcollections/btree/set.rs @@ -11,9 +11,6 @@ // This is pretty much entirely stolen from TreeSet, since BTreeMap has an identical interface // to TreeMap -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp::Ordering::{self, Less, Greater, Equal}; use core::fmt::Debug; use core::fmt; diff --git a/src/libcollections/enum_set.rs b/src/libcollections/enum_set.rs index e74726baf11..246c213a19b 100644 --- a/src/libcollections/enum_set.rs +++ b/src/libcollections/enum_set.rs @@ -17,9 +17,6 @@ reason = "matches collection reform specification, \ waiting for dust to settle")] -#[cfg(stage0)] -use core::prelude::v1::*; - use core::marker; use core::fmt; use core::iter::{FromIterator}; diff --git a/src/libcollections/lib.rs b/src/libcollections/lib.rs index 3be5f32d6c2..6abfaa888d9 100644 --- a/src/libcollections/lib.rs +++ b/src/libcollections/lib.rs @@ -59,13 +59,10 @@ #![feature(utf8_error)] #![cfg_attr(test, feature(rand, test))] #![cfg_attr(not(test), feature(str_words))] -#![cfg_attr(stage0, feature(core, core_prelude))] #![feature(no_std)] #![no_std] -#[cfg(stage0)] #[macro_use] extern crate core; - extern crate rustc_unicode; extern crate alloc; diff --git a/src/libcollections/linked_list.rs b/src/libcollections/linked_list.rs index 697cfea197c..50b5db758c1 100644 --- a/src/libcollections/linked_list.rs +++ b/src/libcollections/linked_list.rs @@ -21,9 +21,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use alloc::boxed::Box; use core::cmp::Ordering; use core::fmt; diff --git a/src/libcollections/string.rs b/src/libcollections/string.rs index 2bd5b315c4c..aa41c57b927 100644 --- a/src/libcollections/string.rs +++ b/src/libcollections/string.rs @@ -12,9 +12,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use core::fmt; use core::hash; use core::iter::FromIterator; diff --git a/src/libcollections/vec.rs b/src/libcollections/vec.rs index 83786648ea0..45b0dea493f 100644 --- a/src/libcollections/vec.rs +++ b/src/libcollections/vec.rs @@ -58,9 +58,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use alloc::raw_vec::RawVec; use alloc::boxed::Box; use alloc::heap::EMPTY; diff --git a/src/libcollections/vec_deque.rs b/src/libcollections/vec_deque.rs index b55436c7057..f189d7b80d9 100644 --- a/src/libcollections/vec_deque.rs +++ b/src/libcollections/vec_deque.rs @@ -18,9 +18,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp::Ordering; use core::fmt; use core::iter::{self, repeat, FromIterator, RandomAccessIterator}; diff --git a/src/libcollections/vec_map.rs b/src/libcollections/vec_map.rs index 8be80a67ce7..93f8db23e56 100644 --- a/src/libcollections/vec_map.rs +++ b/src/libcollections/vec_map.rs @@ -20,9 +20,6 @@ use self::Entry::*; -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp::{max, Ordering}; use core::fmt; use core::hash::{Hash, Hasher}; diff --git a/src/libcore/lib.rs b/src/libcore/lib.rs index 56fb4c71a6a..69b3ce43b95 100644 --- a/src/libcore/lib.rs +++ b/src/libcore/lib.rs @@ -60,28 +60,26 @@ html_playground_url = "http://play.rust-lang.org/")] #![doc(test(no_crate_inject))] -#![cfg_attr(stage0, feature(no_std))] -#![cfg_attr(stage0, no_std)] -#![cfg_attr(not(stage0), feature(no_core))] -#![cfg_attr(not(stage0), no_core)] +#![no_core] #![allow(raw_pointer_derive)] #![deny(missing_docs)] +#![feature(allow_internal_unstable)] #![feature(associated_type_defaults)] +#![feature(concat_idents)] +#![feature(const_fn)] +#![feature(custom_attribute)] +#![feature(fundamental)] #![feature(intrinsics)] #![feature(lang_items)] +#![feature(no_core)] #![feature(on_unimplemented)] +#![feature(optin_builtin_traits)] +#![feature(reflect)] +#![feature(rustc_attrs)] #![feature(simd)] #![feature(staged_api)] #![feature(unboxed_closures)] -#![feature(rustc_attrs)] -#![feature(optin_builtin_traits)] -#![feature(fundamental)] -#![feature(concat_idents)] -#![feature(reflect)] -#![feature(custom_attribute)] -#![feature(const_fn)] -#![feature(allow_internal_unstable)] #[macro_use] mod macros; @@ -159,25 +157,3 @@ pub mod fmt; // note: does not need to be public mod tuple; - -// A curious inner-module that's not exported that contains the bindings of core -// so that compiler-expanded references to `core::$foo` can be resolved within -// core itself. -// -// Note that no crate-defined macros require this module due to the existence of -// the `$crate` meta variable, only those expansions defined in the compiler -// require this. This is because the compiler doesn't currently know that it's -// compiling the core library when it's compiling this library, so it expands -// all references to `::core::$foo` -#[doc(hidden)] -#[cfg(stage0)] -mod core { - pub use intrinsics; // derive(PartialOrd) - pub use fmt; // format_args! - pub use clone; // derive(Clone) - pub use cmp; // derive(Ord) - pub use hash; // derive(Hash) - pub use marker; // derive(Copy) - pub use option; // iterator protocol - pub use iter; // iterator protocol -} diff --git a/src/liblibc/lib.rs b/src/liblibc/lib.rs index d895a3e62a3..e315c73990b 100644 --- a/src/liblibc/lib.rs +++ b/src/liblibc/lib.rs @@ -15,7 +15,6 @@ #![cfg_attr(not(feature = "cargo-build"), unstable(feature = "libc", reason = "use `libc` from crates.io"))] #![cfg_attr(not(feature = "cargo-build"), feature(staged_api, no_std))] -#![cfg_attr(all(not(feature = "cargo-build"), stage0), feature(core))] #![cfg_attr(not(feature = "cargo-build"), staged_api)] #![cfg_attr(not(feature = "cargo-build"), no_std)] #![doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png", @@ -79,7 +78,6 @@ #![allow(bad_style, raw_pointer_derive)] #![cfg_attr(target_os = "nacl", allow(unused_imports))] #[cfg(feature = "cargo-build")] extern crate std as core; -#[cfg(all(stage0, not(feature = "cargo-build")))] extern crate core; #[cfg(test)] extern crate std; #[cfg(test)] extern crate test; diff --git a/src/librand/chacha.rs b/src/librand/chacha.rs index 51000ed166b..db81ff5c070 100644 --- a/src/librand/chacha.rs +++ b/src/librand/chacha.rs @@ -10,9 +10,6 @@ //! The ChaCha random number generator. -#[cfg(stage0)] -use core::prelude::v1::*; - use {Rng, SeedableRng, Rand}; const KEY_WORDS : usize = 8; // 8 words for the 256-bit key diff --git a/src/librand/distributions/mod.rs b/src/librand/distributions/mod.rs index 6f003b8b9ad..5defe174cf5 100644 --- a/src/librand/distributions/mod.rs +++ b/src/librand/distributions/mod.rs @@ -17,9 +17,6 @@ //! internally. The `IndependentSample` trait is for generating values //! that do not need to record state. -#[cfg(stage0)] -use core::prelude::v1::*; - use core::num::Float; use core::marker::PhantomData; diff --git a/src/librand/distributions/range.rs b/src/librand/distributions/range.rs index 52a5219a380..e196708368a 100644 --- a/src/librand/distributions/range.rs +++ b/src/librand/distributions/range.rs @@ -12,9 +12,6 @@ // this is surprisingly complicated to be both generic & correct -#[cfg(stage0)] -use core::prelude::v1::PartialOrd; - use Rng; use distributions::{Sample, IndependentSample}; diff --git a/src/librand/isaac.rs b/src/librand/isaac.rs index 6827d9c6f13..f51483cc11f 100644 --- a/src/librand/isaac.rs +++ b/src/librand/isaac.rs @@ -12,9 +12,6 @@ #![allow(non_camel_case_types)] -#[cfg(stage0)] -use core::prelude::v1::*; - use core::slice; use core::iter::repeat; use core::num::Wrapping as w; diff --git a/src/librand/lib.rs b/src/librand/lib.rs index ace2c2fc21d..311f44158ec 100644 --- a/src/librand/lib.rs +++ b/src/librand/lib.rs @@ -34,20 +34,14 @@ #![feature(num_bits_bytes)] #![feature(staged_api)] #![feature(step_by)] -#![cfg_attr(stage0, feature(core, core_prelude))] #![cfg_attr(test, feature(test, rand, rustc_private, iter_order))] #![allow(deprecated)] -#[cfg(stage0)] #[macro_use] extern crate core; - #[cfg(test)] #[macro_use] extern crate std; #[cfg(test)] #[macro_use] extern crate log; -#[cfg(stage0)] -use core::prelude::v1::*; - use core::marker::PhantomData; pub use isaac::{IsaacRng, Isaac64Rng}; diff --git a/src/librand/rand_impls.rs b/src/librand/rand_impls.rs index 3db98cfe2f4..04093db4b6f 100644 --- a/src/librand/rand_impls.rs +++ b/src/librand/rand_impls.rs @@ -10,9 +10,6 @@ //! The implementations of `Rand` for the built-in types. -#[cfg(stage0)] -use core::prelude::v1::*; - use core::char; use core::isize; use core::usize; diff --git a/src/librand/reseeding.rs b/src/librand/reseeding.rs index 6fe7dd09854..99fe2bb5ab5 100644 --- a/src/librand/reseeding.rs +++ b/src/librand/reseeding.rs @@ -11,9 +11,6 @@ //! A wrapper around another RNG that reseeds it after it //! generates a certain number of random bytes. -#[cfg(stage0)] -use core::prelude::v1::*; - use {Rng, SeedableRng}; /// How many bytes of entropy the underling RNG is allowed to generate diff --git a/src/librustc_llvm/lib.rs b/src/librustc_llvm/lib.rs index e0d585d6f5b..a10e9baf9cc 100644 --- a/src/librustc_llvm/lib.rs +++ b/src/librustc_llvm/lib.rs @@ -31,7 +31,7 @@ #![feature(link_args)] #![feature(staged_api)] #![feature(vec_push_all)] -#![cfg_attr(not(stage0), feature(linked_from))] +#![feature(linked_from)] extern crate libc; #[macro_use] #[no_link] extern crate rustc_bitflags; @@ -599,7 +599,7 @@ pub mod debuginfo { // automatically updated whenever LLVM is updated to include an up-to-date // set of the libraries we need to link to LLVM for. #[link(name = "rustllvm", kind = "static")] -#[cfg_attr(not(stage0), linked_from = "rustllvm")] // not quite true but good enough +#[linked_from = "rustllvm"] // not quite true but good enough extern { /* Create and destroy contexts. */ pub fn LLVMContextCreate() -> ContextRef; diff --git a/src/librustc_unicode/lib.rs b/src/librustc_unicode/lib.rs index 6cd8b72cb5c..08b2d4e3761 100644 --- a/src/librustc_unicode/lib.rs +++ b/src/librustc_unicode/lib.rs @@ -41,9 +41,6 @@ #![feature(lang_items)] #![feature(no_std)] #![feature(staged_api)] -#![cfg_attr(stage0, feature(core, core_prelude))] - -#[cfg(stage0)] extern crate core; mod normalize; mod tables; diff --git a/src/librustc_unicode/u_str.rs b/src/librustc_unicode/u_str.rs index 37443cfa70c..a938312248f 100644 --- a/src/librustc_unicode/u_str.rs +++ b/src/librustc_unicode/u_str.rs @@ -14,8 +14,6 @@ //! unicode parts of the CharExt trait. use self::GraphemeState::*; -#[cfg(stage0)] -use core::prelude::v1::*; use core::char; use core::cmp; diff --git a/src/libstd/ffi/os_str.rs b/src/libstd/ffi/os_str.rs index 83d76481d49..8831830f799 100644 --- a/src/libstd/ffi/os_str.rs +++ b/src/libstd/ffi/os_str.rs @@ -32,9 +32,6 @@ #![unstable(feature = "os_str", reason = "recently added as part of path/io reform")] -#[cfg(stage0)] -use core::prelude::v1::*; - use borrow::{Borrow, Cow, ToOwned}; use ffi::CString; use fmt::{self, Debug}; diff --git a/src/libstd/fs.rs b/src/libstd/fs.rs index 6995ed07e99..ba32ffc49d4 100644 --- a/src/libstd/fs.rs +++ b/src/libstd/fs.rs @@ -17,9 +17,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use fmt; use ffi::OsString; use io::{self, SeekFrom, Seek, Read, Write}; diff --git a/src/libstd/io/cursor.rs b/src/libstd/io/cursor.rs index 8033d77ff6a..9590f0b7aa7 100644 --- a/src/libstd/io/cursor.rs +++ b/src/libstd/io/cursor.rs @@ -292,9 +292,6 @@ impl Write for Cursor> { #[cfg(test)] mod tests { - #[cfg(stage0)] - use core::prelude::v1::*; - use io::prelude::*; use io::{Cursor, SeekFrom}; use vec::Vec; diff --git a/src/libstd/io/impls.rs b/src/libstd/io/impls.rs index 864870a5905..a5c8ba335c1 100644 --- a/src/libstd/io/impls.rs +++ b/src/libstd/io/impls.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use core::prelude::v1::*; - use boxed::Box; use cmp; use io::{self, SeekFrom, Read, Write, Seek, BufRead, Error, ErrorKind}; diff --git a/src/libstd/io/util.rs b/src/libstd/io/util.rs index 6e218f6ca7e..07a9548224a 100644 --- a/src/libstd/io/util.rs +++ b/src/libstd/io/util.rs @@ -10,9 +10,6 @@ #![allow(missing_copy_implementations)] -#[cfg(stage0)] -use prelude::v1::*; - use io::{self, Read, Write, ErrorKind, BufRead}; /// Copies the entire contents of a reader into a writer. diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs index 7baa7558e52..be6f81bc9aa 100644 --- a/src/libstd/lib.rs +++ b/src/libstd/lib.rs @@ -249,7 +249,6 @@ #![cfg_attr(test, feature(float_from_str_radix, range_inclusive, float_extras, hash_default))] #![cfg_attr(test, feature(test, rustc_private, float_consts))] #![cfg_attr(target_env = "msvc", feature(link_args))] -#![cfg_attr(stage0, feature(core, core_prelude))] // Don't link to std. We are std. #![no_std] @@ -257,8 +256,6 @@ #![allow(trivial_casts)] #![deny(missing_docs)] -#[cfg(stage0)] #[macro_use] extern crate core; - #[cfg(test)] extern crate test; #[cfg(test)] #[macro_use] extern crate log; diff --git a/src/libstd/net/udp.rs b/src/libstd/net/udp.rs index 290aa6e2fda..1e1ffc19900 100644 --- a/src/libstd/net/udp.rs +++ b/src/libstd/net/udp.rs @@ -11,9 +11,6 @@ #![unstable(feature = "udp", reason = "remaining functions have not been \ scrutinized enough to be stabilized")] -#[cfg(stage0)] -use prelude::v1::*; - use fmt; use io::{self, Error, ErrorKind}; use net::{ToSocketAddrs, SocketAddr, IpAddr}; diff --git a/src/libstd/num/f32.rs b/src/libstd/num/f32.rs index 64da75e94db..6a8026a807e 100644 --- a/src/libstd/num/f32.rs +++ b/src/libstd/num/f32.rs @@ -15,9 +15,6 @@ #![stable(feature = "rust1", since = "1.0.0")] #![allow(missing_docs)] -#[cfg(stage0)] -use prelude::v1::*; - use core::num; #[cfg(not(target_env = "msvc"))] use intrinsics; diff --git a/src/libstd/num/f64.rs b/src/libstd/num/f64.rs index fcba821522e..e757ff90fdd 100644 --- a/src/libstd/num/f64.rs +++ b/src/libstd/num/f64.rs @@ -15,9 +15,6 @@ #![stable(feature = "rust1", since = "1.0.0")] #![allow(missing_docs)] -#[cfg(stage0)] -use prelude::v1::*; - use core::num; use intrinsics; use libc::c_int; diff --git a/src/libstd/num/mod.rs b/src/libstd/num/mod.rs index db7fd463e07..d1ef763e0f6 100644 --- a/src/libstd/num/mod.rs +++ b/src/libstd/num/mod.rs @@ -43,8 +43,6 @@ pub fn test_num(ten: T, two: T) where #[cfg(test)] mod tests { - #[cfg(stage0)] - use core::prelude::v1::*; use super::*; use i8; use i16; diff --git a/src/libstd/path.rs b/src/libstd/path.rs index 5b456b580e5..0de6b74aabc 100644 --- a/src/libstd/path.rs +++ b/src/libstd/path.rs @@ -98,9 +98,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use core::prelude::v1::*; - use ascii::*; use borrow::{Borrow, IntoCow, ToOwned, Cow}; use cmp; @@ -135,8 +132,6 @@ use self::platform::{is_sep_byte, is_verbatim_sep, MAIN_SEP_STR, parse_prefix}; #[cfg(unix)] mod platform { use super::Prefix; - #[cfg(stage0)] - use core::prelude::v1::*; use ffi::OsStr; #[inline] @@ -159,8 +154,6 @@ mod platform { #[cfg(windows)] mod platform { - #[cfg(stage0)] - use core::prelude::v1::*; use ascii::*; use super::{os_str_as_u8_slice, u8_slice_as_os_str, Prefix}; @@ -1750,8 +1743,6 @@ impl AsRef for PathBuf { #[cfg(test)] mod tests { use super::*; - #[cfg(stage0)] - use core::prelude::v1::*; use string::{ToString, String}; use vec::Vec; diff --git a/src/libstd/rand/mod.rs b/src/libstd/rand/mod.rs index df9cd98084b..ee46ec5c9c4 100644 --- a/src/libstd/rand/mod.rs +++ b/src/libstd/rand/mod.rs @@ -57,9 +57,6 @@ #![unstable(feature = "rand")] -#[cfg(stage0)] -use prelude::v1::*; - use cell::RefCell; use io; use mem; diff --git a/src/libstd/rand/os.rs b/src/libstd/rand/os.rs index bd31fe08421..e6d8c14dc1d 100644 --- a/src/libstd/rand/os.rs +++ b/src/libstd/rand/os.rs @@ -15,7 +15,6 @@ pub use self::imp::OsRng; #[cfg(all(unix, not(target_os = "ios")))] mod imp { - #[cfg(stage0)] use prelude::v1::*; use self::OsRngInner::*; use fs::File; @@ -249,9 +248,6 @@ mod imp { #[cfg(windows)] mod imp { - #[cfg(stage0)] - use prelude::v1::*; - use io; use mem; use rand::Rng; diff --git a/src/libstd/rand/reader.rs b/src/libstd/rand/reader.rs index 8ac2722f65a..36adf44cd3a 100644 --- a/src/libstd/rand/reader.rs +++ b/src/libstd/rand/reader.rs @@ -12,7 +12,6 @@ #![allow(dead_code)] -#[cfg(stage0)] use prelude::v1::*; use io::prelude::*; use rand::Rng; diff --git a/src/libstd/rt/args.rs b/src/libstd/rt/args.rs index e77a2bbd0b9..cf8bac31057 100644 --- a/src/libstd/rt/args.rs +++ b/src/libstd/rt/args.rs @@ -19,8 +19,6 @@ //! //! FIXME #7756: Would be nice for this to not exist. -#[cfg(stage0)] -use core::prelude::v1::*; use vec::Vec; /// One-time global initialization. @@ -141,8 +139,6 @@ mod imp { target_os = "ios", target_os = "windows"))] mod imp { - #[cfg(stage0)] - use core::prelude::v1::*; use vec::Vec; pub unsafe fn init(_argc: isize, _argv: *const *const u8) { diff --git a/src/libstd/rt/backtrace.rs b/src/libstd/rt/backtrace.rs index 18d93cba8bc..9e7ed89bae1 100644 --- a/src/libstd/rt/backtrace.rs +++ b/src/libstd/rt/backtrace.rs @@ -12,9 +12,6 @@ #![allow(non_camel_case_types)] -#[cfg(stage0)] -use prelude::v1::*; - use env; use sync::atomic::{self, Ordering}; diff --git a/src/libstd/sync/future.rs b/src/libstd/sync/future.rs index d0314da19d3..506b8260278 100644 --- a/src/libstd/sync/future.rs +++ b/src/libstd/sync/future.rs @@ -39,8 +39,6 @@ outside in crates.io first")] #![allow(deprecated)] -#[cfg(stage0)] -use core::prelude::v1::*; use core::mem::replace; use boxed::Box; diff --git a/src/libstd/sync/mpsc/mod.rs b/src/libstd/sync/mpsc/mod.rs index 954edefcc45..c37c0405bbb 100644 --- a/src/libstd/sync/mpsc/mod.rs +++ b/src/libstd/sync/mpsc/mod.rs @@ -265,9 +265,6 @@ // And now that you've seen all the races that I found and attempted to fix, // here's the code for you to find some more! -#[cfg(stage0)] -use prelude::v1::*; - use sync::Arc; use error; use fmt; diff --git a/src/libstd/sync/mpsc/mpsc_queue.rs b/src/libstd/sync/mpsc/mpsc_queue.rs index f45032d327f..e4eba3d3d20 100644 --- a/src/libstd/sync/mpsc/mpsc_queue.rs +++ b/src/libstd/sync/mpsc/mpsc_queue.rs @@ -40,9 +40,6 @@ pub use self::PopResult::*; -#[cfg(stage0)] -use core::prelude::v1::*; - use alloc::boxed::Box; use core::ptr; use core::cell::UnsafeCell; diff --git a/src/libstd/sync/mpsc/oneshot.rs b/src/libstd/sync/mpsc/oneshot.rs index b84cb3b5472..cb930280964 100644 --- a/src/libstd/sync/mpsc/oneshot.rs +++ b/src/libstd/sync/mpsc/oneshot.rs @@ -37,9 +37,6 @@ pub use self::UpgradeResult::*; pub use self::SelectionResult::*; use self::MyUpgrade::*; -#[cfg(stage0)] -use core::prelude::v1::*; - use sync::mpsc::Receiver; use sync::mpsc::blocking::{self, SignalToken}; use core::mem; diff --git a/src/libstd/sync/mpsc/select.rs b/src/libstd/sync/mpsc/select.rs index c46e61cf414..56d903fed3b 100644 --- a/src/libstd/sync/mpsc/select.rs +++ b/src/libstd/sync/mpsc/select.rs @@ -57,9 +57,6 @@ but no guarantees beyond this are being made")] -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cell::{Cell, UnsafeCell}; use core::marker; use core::ptr; diff --git a/src/libstd/sync/mpsc/shared.rs b/src/libstd/sync/mpsc/shared.rs index 8c019395d30..a3779931c7b 100644 --- a/src/libstd/sync/mpsc/shared.rs +++ b/src/libstd/sync/mpsc/shared.rs @@ -20,9 +20,6 @@ pub use self::Failure::*; -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp; use core::isize; diff --git a/src/libstd/sync/mpsc/spsc_queue.rs b/src/libstd/sync/mpsc/spsc_queue.rs index 5c0db521007..819f75c006b 100644 --- a/src/libstd/sync/mpsc/spsc_queue.rs +++ b/src/libstd/sync/mpsc/spsc_queue.rs @@ -33,9 +33,6 @@ //! concurrently between two threads. This data structure is safe to use and //! enforces the semantics that there is one pusher and one popper. -#[cfg(stage0)] -use core::prelude::v1::*; - use alloc::boxed::Box; use core::ptr; use core::cell::UnsafeCell; diff --git a/src/libstd/sync/mpsc/stream.rs b/src/libstd/sync/mpsc/stream.rs index a9514da4698..a9da1b12f7d 100644 --- a/src/libstd/sync/mpsc/stream.rs +++ b/src/libstd/sync/mpsc/stream.rs @@ -22,9 +22,6 @@ pub use self::UpgradeResult::*; pub use self::SelectionResult::*; use self::Message::*; -#[cfg(stage0)] -use core::prelude::v1::*; - use core::cmp; use core::isize; use thread; diff --git a/src/libstd/sync/mpsc/sync.rs b/src/libstd/sync/mpsc/sync.rs index 7c9298fff2a..84d758cf9b3 100644 --- a/src/libstd/sync/mpsc/sync.rs +++ b/src/libstd/sync/mpsc/sync.rs @@ -33,9 +33,6 @@ /// of a synchronous channel. There are a few branches for the unbuffered case, /// but they're mostly just relevant to blocking senders. -#[cfg(stage0)] -use core::prelude::v1::*; - pub use self::Failure::*; use self::Blocker::*; diff --git a/src/libstd/sync/once.rs b/src/libstd/sync/once.rs index 53191e14bec..a91e1321149 100644 --- a/src/libstd/sync/once.rs +++ b/src/libstd/sync/once.rs @@ -13,9 +13,6 @@ //! This primitive is meant to be used to run one-time initialization. An //! example use case would be for initializing an FFI library. -#[cfg(stage0)] -use prelude::v1::*; - use isize; use sync::atomic::{AtomicIsize, Ordering}; use sync::StaticMutex; diff --git a/src/libstd/sys/common/backtrace.rs b/src/libstd/sys/common/backtrace.rs index 17953d0af4e..7f56afc9e1f 100644 --- a/src/libstd/sys/common/backtrace.rs +++ b/src/libstd/sys/common/backtrace.rs @@ -8,8 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; use io::prelude::*; use io; diff --git a/src/libstd/sys/common/mod.rs b/src/libstd/sys/common/mod.rs index d63b66c42c7..aca1f42c529 100644 --- a/src/libstd/sys/common/mod.rs +++ b/src/libstd/sys/common/mod.rs @@ -10,9 +10,6 @@ #![allow(missing_docs)] -#[cfg(stage0)] -use prelude::v1::*; - pub mod backtrace; pub mod condvar; pub mod mutex; @@ -51,7 +48,3 @@ pub trait IntoInner { pub trait FromInner { fn from_inner(inner: Inner) -> Self; } - -#[cfg(stage0)] -#[lang = "stack_exhausted"] -pub fn stack_exhausted() {} diff --git a/src/libstd/sys/common/poison.rs b/src/libstd/sys/common/poison.rs index 196fe37d456..c6917d8fca5 100644 --- a/src/libstd/sys/common/poison.rs +++ b/src/libstd/sys/common/poison.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use cell::Cell; use error::{Error}; use fmt; diff --git a/src/libstd/sys/common/thread_info.rs b/src/libstd/sys/common/thread_info.rs index fb4e0ec70e0..0467c67167b 100644 --- a/src/libstd/sys/common/thread_info.rs +++ b/src/libstd/sys/common/thread_info.rs @@ -10,9 +10,6 @@ #![allow(dead_code)] // stack_guard isn't used right now on all platforms -#[cfg(stage0)] -use core::prelude::v1::*; - use cell::RefCell; use string::String; use thread::Thread; diff --git a/src/libstd/sys/common/thread_local.rs b/src/libstd/sys/common/thread_local.rs index 2269a053874..f68c57c86ef 100644 --- a/src/libstd/sys/common/thread_local.rs +++ b/src/libstd/sys/common/thread_local.rs @@ -58,9 +58,6 @@ #![unstable(feature = "thread_local_internals")] #![allow(dead_code)] // sys isn't exported yet -#[cfg(stage0)] -use prelude::v1::*; - use sync::atomic::{self, AtomicUsize, Ordering}; use sys::thread_local as imp; diff --git a/src/libstd/sys/common/wtf8.rs b/src/libstd/sys/common/wtf8.rs index 0a5f4563dea..9e4a80a411b 100644 --- a/src/libstd/sys/common/wtf8.rs +++ b/src/libstd/sys/common/wtf8.rs @@ -25,9 +25,6 @@ // unix (it's mostly used on windows), so don't worry about dead code here. #![allow(dead_code)] -#[cfg(stage0)] -use core::prelude::v1::*; - use core::char::{encode_utf8_raw, encode_utf16_raw}; use core::str::next_code_point; diff --git a/src/libstd/sys/unix/backtrace.rs b/src/libstd/sys/unix/backtrace.rs index 4128431ee64..bfd26fe4439 100644 --- a/src/libstd/sys/unix/backtrace.rs +++ b/src/libstd/sys/unix/backtrace.rs @@ -83,8 +83,6 @@ /// to symbols. This is a bit of a hokey implementation as-is, but it works for /// all unix platforms we support right now, so it at least gets the job done. -#[cfg(stage0)] -use prelude::v1::*; use io::prelude::*; use ffi::CStr; diff --git a/src/libstd/sys/unix/condvar.rs b/src/libstd/sys/unix/condvar.rs index 5d18c1d6280..b9538867b25 100644 --- a/src/libstd/sys/unix/condvar.rs +++ b/src/libstd/sys/unix/condvar.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use cell::UnsafeCell; use libc; use ptr; diff --git a/src/libstd/sys/unix/ext/fs.rs b/src/libstd/sys/unix/ext/fs.rs index dca7f6e829f..9bcd62dbdd1 100644 --- a/src/libstd/sys/unix/ext/fs.rs +++ b/src/libstd/sys/unix/ext/fs.rs @@ -12,9 +12,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use prelude::v1::*; - use fs::{self, Permissions, OpenOptions}; use io; use libc; diff --git a/src/libstd/sys/unix/ext/process.rs b/src/libstd/sys/unix/ext/process.rs index e984c577935..4ff6daf84c1 100644 --- a/src/libstd/sys/unix/ext/process.rs +++ b/src/libstd/sys/unix/ext/process.rs @@ -14,8 +14,6 @@ use os::unix::raw::{uid_t, gid_t}; use os::unix::io::{FromRawFd, RawFd, AsRawFd, IntoRawFd}; -#[cfg(stage0)] -use prelude::v1::*; use process; use sys; use sys_common::{AsInnerMut, AsInner, FromInner, IntoInner}; diff --git a/src/libstd/sys/unix/fd.rs b/src/libstd/sys/unix/fd.rs index bdbe120f79d..4ac498f77ce 100644 --- a/src/libstd/sys/unix/fd.rs +++ b/src/libstd/sys/unix/fd.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use core::prelude::v1::*; - use io; use libc::{self, c_int, size_t, c_void}; use mem; diff --git a/src/libstd/sys/unix/fs.rs b/src/libstd/sys/unix/fs.rs index e671b2c8e0d..922a213f9c2 100644 --- a/src/libstd/sys/unix/fs.rs +++ b/src/libstd/sys/unix/fs.rs @@ -8,8 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use core::prelude::v1::*; use io::prelude::*; use os::unix::prelude::*; diff --git a/src/libstd/sys/unix/mod.rs b/src/libstd/sys/unix/mod.rs index 85dc8752443..2efca0257f3 100644 --- a/src/libstd/sys/unix/mod.rs +++ b/src/libstd/sys/unix/mod.rs @@ -11,9 +11,6 @@ #![allow(missing_docs)] #![allow(non_camel_case_types)] -#[cfg(stage0)] -use prelude::v1::*; - use io::{self, ErrorKind}; use libc; use num::One; diff --git a/src/libstd/sys/unix/mutex.rs b/src/libstd/sys/unix/mutex.rs index a6132b37a66..e4c231ff971 100644 --- a/src/libstd/sys/unix/mutex.rs +++ b/src/libstd/sys/unix/mutex.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use cell::UnsafeCell; use sys::sync as ffi; use mem; diff --git a/src/libstd/sys/unix/os_str.rs b/src/libstd/sys/unix/os_str.rs index e21d88676e7..f0f08a72ed8 100644 --- a/src/libstd/sys/unix/os_str.rs +++ b/src/libstd/sys/unix/os_str.rs @@ -11,9 +11,6 @@ /// The underlying OsString/OsStr implementation on Unix systems: just /// a `Vec`/`[u8]`. -#[cfg(stage0)] -use core::prelude::v1::*; - use borrow::Cow; use fmt::{self, Debug}; use vec::Vec; diff --git a/src/libstd/sys/unix/pipe.rs b/src/libstd/sys/unix/pipe.rs index 2abd74bea1b..5c29c4c0811 100644 --- a/src/libstd/sys/unix/pipe.rs +++ b/src/libstd/sys/unix/pipe.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use sys::fd::FileDesc; use io; use libc; diff --git a/src/libstd/sys/unix/rwlock.rs b/src/libstd/sys/unix/rwlock.rs index 50b4907e6ca..788bff62430 100644 --- a/src/libstd/sys/unix/rwlock.rs +++ b/src/libstd/sys/unix/rwlock.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use libc; use cell::UnsafeCell; use sys::sync as ffi; diff --git a/src/libstd/sys/unix/stack_overflow.rs b/src/libstd/sys/unix/stack_overflow.rs index 4e4cf2b0ed1..1aa75fa18b7 100644 --- a/src/libstd/sys/unix/stack_overflow.rs +++ b/src/libstd/sys/unix/stack_overflow.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use core::prelude::v1::*; - use libc; use self::imp::{make_handler, drop_handler}; diff --git a/src/libstd/sys/unix/stdio.rs b/src/libstd/sys/unix/stdio.rs index 8542c660c26..c87800a1498 100644 --- a/src/libstd/sys/unix/stdio.rs +++ b/src/libstd/sys/unix/stdio.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use io; use libc; use sys::fd::FileDesc; diff --git a/src/libstd/sys/unix/thread.rs b/src/libstd/sys/unix/thread.rs index fc0bb81f9a8..8d59461f1e4 100644 --- a/src/libstd/sys/unix/thread.rs +++ b/src/libstd/sys/unix/thread.rs @@ -163,9 +163,6 @@ impl Drop for Thread { not(target_os = "netbsd"), not(target_os = "openbsd")))] pub mod guard { - #[cfg(stage0)] - use prelude::v1::*; - pub unsafe fn current() -> Option { None } pub unsafe fn init() -> Option { None } } diff --git a/src/libstd/sys/unix/thread_local.rs b/src/libstd/sys/unix/thread_local.rs index 5626446b31c..c375788fdc1 100644 --- a/src/libstd/sys/unix/thread_local.rs +++ b/src/libstd/sys/unix/thread_local.rs @@ -10,8 +10,6 @@ #![allow(dead_code)] // sys isn't exported yet -#[cfg(stage0)] -use prelude::v1::*; use libc::c_int; pub type Key = pthread_key_t; diff --git a/src/libstd/sys/windows/backtrace.rs b/src/libstd/sys/windows/backtrace.rs index d84513c5f95..7078ee92085 100644 --- a/src/libstd/sys/windows/backtrace.rs +++ b/src/libstd/sys/windows/backtrace.rs @@ -24,8 +24,6 @@ #![allow(dead_code)] -#[cfg(stage0)] -use prelude::v1::*; use io::prelude::*; use dynamic_lib::DynamicLibrary; diff --git a/src/libstd/sys/windows/condvar.rs b/src/libstd/sys/windows/condvar.rs index f3edcfd420c..ac76479d7db 100644 --- a/src/libstd/sys/windows/condvar.rs +++ b/src/libstd/sys/windows/condvar.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use cell::UnsafeCell; use libc::{self, DWORD}; use sys::c; diff --git a/src/libstd/sys/windows/ext/fs.rs b/src/libstd/sys/windows/ext/fs.rs index e15d1f0ec15..66f42db42cf 100644 --- a/src/libstd/sys/windows/ext/fs.rs +++ b/src/libstd/sys/windows/ext/fs.rs @@ -12,9 +12,6 @@ #![stable(feature = "rust1", since = "1.0.0")] -#[cfg(stage0)] -use prelude::v1::*; - use fs::{OpenOptions, Metadata}; use io; use path::Path; diff --git a/src/libstd/sys/windows/fs.rs b/src/libstd/sys/windows/fs.rs index 8d81d6576ff..b8c3f1e7b35 100644 --- a/src/libstd/sys/windows/fs.rs +++ b/src/libstd/sys/windows/fs.rs @@ -8,8 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use core::prelude::v1::*; use io::prelude::*; use os::windows::prelude::*; diff --git a/src/libstd/sys/windows/handle.rs b/src/libstd/sys/windows/handle.rs index 91fe131c251..a9e9b0e2520 100644 --- a/src/libstd/sys/windows/handle.rs +++ b/src/libstd/sys/windows/handle.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use io::ErrorKind; use io; use libc::funcs::extra::kernel32::{GetCurrentProcess, DuplicateHandle}; diff --git a/src/libstd/sys/windows/net.rs b/src/libstd/sys/windows/net.rs index f2aca8d1a6e..02c5bc1f0ab 100644 --- a/src/libstd/sys/windows/net.rs +++ b/src/libstd/sys/windows/net.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use io; use libc::consts::os::extra::INVALID_SOCKET; use libc::{self, c_int, c_void}; diff --git a/src/libstd/sys/windows/pipe.rs b/src/libstd/sys/windows/pipe.rs index 4044c429d49..7e286b91f4a 100644 --- a/src/libstd/sys/windows/pipe.rs +++ b/src/libstd/sys/windows/pipe.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use io; use libc; use sys::cvt; diff --git a/src/libstd/sys/windows/rwlock.rs b/src/libstd/sys/windows/rwlock.rs index 010ffe76fba..3e81ebfcedf 100644 --- a/src/libstd/sys/windows/rwlock.rs +++ b/src/libstd/sys/windows/rwlock.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use cell::UnsafeCell; use sys::c; diff --git a/src/libstd/sys/windows/thread.rs b/src/libstd/sys/windows/thread.rs index a9d094375b2..cf1b3ebddb9 100644 --- a/src/libstd/sys/windows/thread.rs +++ b/src/libstd/sys/windows/thread.rs @@ -81,9 +81,6 @@ impl Thread { } pub mod guard { - #[cfg(stage0)] - use prelude::v1::*; - pub unsafe fn current() -> Option { None } pub unsafe fn init() -> Option { None } } diff --git a/src/libstd/thread/local.rs b/src/libstd/thread/local.rs index 0615033736e..3bf170b5fe2 100644 --- a/src/libstd/thread/local.rs +++ b/src/libstd/thread/local.rs @@ -12,9 +12,6 @@ #![unstable(feature = "thread_local_internals")] -#[cfg(stage0)] -use prelude::v1::*; - use cell::UnsafeCell; // Sure wish we had macro hygiene, no? @@ -272,9 +269,6 @@ impl LocalKey { not(no_elf_tls)))] #[doc(hidden)] mod imp { - #[cfg(stage0)] - use prelude::v1::*; - use cell::{Cell, UnsafeCell}; use intrinsics; use ptr; diff --git a/src/libstd/thread/scoped_tls.rs b/src/libstd/thread/scoped_tls.rs index 1ea33a01791..303ab0f9f01 100644 --- a/src/libstd/thread/scoped_tls.rs +++ b/src/libstd/thread/scoped_tls.rs @@ -42,9 +42,6 @@ #![unstable(feature = "thread_local_internals")] -#[cfg(stage0)] -use prelude::v1::*; - #[doc(hidden)] pub use self::imp::KeyInner as __KeyInner; @@ -250,9 +247,6 @@ mod imp { no_elf_tls))] #[doc(hidden)] mod imp { - #[cfg(stage0)] - use prelude::v1::*; - use cell::Cell; use marker; use sys_common::thread_local::StaticKey as OsStaticKey; @@ -280,8 +274,6 @@ mod imp { #[cfg(test)] mod tests { use cell::Cell; - #[cfg(stage0)] - use prelude::v1::*; scoped_thread_local!(static FOO: u32); diff --git a/src/libstd/time/duration.rs b/src/libstd/time/duration.rs index 5270f9e6180..ba9c3157b02 100644 --- a/src/libstd/time/duration.rs +++ b/src/libstd/time/duration.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[cfg(stage0)] -use prelude::v1::*; - use ops::{Add, Sub, Mul, Div}; use sys::time::SteadyTime; diff --git a/src/rt/empty.c b/src/rt/empty.c deleted file mode 100644 index 6a54ed322de..00000000000 --- a/src/rt/empty.c +++ /dev/null @@ -1,9 +0,0 @@ -// Copyright 2015 The Rust Project Developers. See the COPYRIGHT -// file at the top-level directory of this distribution and at -// http://rust-lang.org/COPYRIGHT. -// -// Licensed under the Apache License, Version 2.0 or the MIT license -// , at your -// option. This file may not be copied, modified, or distributed -// except according to those terms. diff --git a/src/snapshots.txt b/src/snapshots.txt index 31803fb18f6..704c1b0b835 100644 --- a/src/snapshots.txt +++ b/src/snapshots.txt @@ -1,3 +1,14 @@ +S 2015-08-11 1af31d4 + bitrig-x86_64 0000000000000000000000000000000000000000 + freebsd-i386 0000000000000000000000000000000000000000 + freebsd-x86_64 0000000000000000000000000000000000000000 + linux-i386 e2553bf399cd134a08ef3511a0a6ab0d7a667216 + linux-x86_64 7df8ba9dec63ec77b857066109d4b6250f3d222f + macos-i386 29750870c82a0347f8b8b735a4e2e0da26f5098d + macos-x86_64 c9f2c588238b4c6998190c3abeb33fd6164099a2 + winnt-i386 dc01ac690efdcc40eb6fd8154205a1f21893eb6c + winnt-x86_64 1464a2e54768498222277f904ccd559e27608950 + S 2015-07-26 a5c12f4 bitrig-x86_64 8734eb41ffbe6ddc1120aa2910db4162ec9cf270 freebsd-i386 2fee22adec101e2f952a5548fd1437ce1bd8d26f