diff --git a/src/cargo/cargo.rc b/src/cargo/cargo.rc index 29c6a27d41c..7a426a44cbb 100644 --- a/src/cargo/cargo.rc +++ b/src/cargo/cargo.rc @@ -17,4 +17,12 @@ #[crate_type = "bin"]; +#[no_core]; + +use core(vers = "0.2"); +use std(vers = "0.2"); +use rustc(vers = "0.2"); + +import core::*; + mod pgp; diff --git a/src/cargo/cargo.rs b/src/cargo/cargo.rs index aa8aa706778..759720fbff3 100644 --- a/src/cargo/cargo.rs +++ b/src/cargo/cargo.rs @@ -1,8 +1,5 @@ // cargo.rs - Rust package manager -use rustc; -use std; - import rustc::syntax::{ast, codemap}; import rustc::syntax::parse::parser; import rustc::util::filesearch::{get_cargo_root, get_cargo_root_nearest, diff --git a/src/cargo/pgp.rs b/src/cargo/pgp.rs index 7756f08e8f4..2e872a89e69 100644 --- a/src/cargo/pgp.rs +++ b/src/cargo/pgp.rs @@ -1,5 +1,3 @@ -use std; - fn gpg(args: [str]) -> { status: int, out: str, err: str } { ret run::program_output("gpg", args); } diff --git a/src/compiletest/compiletest.rc b/src/compiletest/compiletest.rc index c652c593c8b..ba04952df5d 100644 --- a/src/compiletest/compiletest.rc +++ b/src/compiletest/compiletest.rc @@ -1,6 +1,11 @@ #[crate_type = "bin"]; -use std; +#[no_core]; + +use core(vers = "0.2"); +use std(vers = "0.2"); + +import core::*; mod procsrv; mod util; diff --git a/src/fuzzer/fuzzer.rc b/src/fuzzer/fuzzer.rc index 39d9779827a..be3352a6ab2 100644 --- a/src/fuzzer/fuzzer.rc +++ b/src/fuzzer/fuzzer.rc @@ -2,8 +2,13 @@ #[crate_type = "bin"]; -use std; -use rustc; +#[no_core]; + +use core(vers = "0.2"); +use std(vers = "0.2"); +use rustc(vers = "0.2"); + +import core::*; // Local Variables: // fill-column: 78; diff --git a/src/libcore/core.rs b/src/libcore/core.rs index 92310166426..39781df0ef0 100644 --- a/src/libcore/core.rs +++ b/src/libcore/core.rs @@ -40,7 +40,7 @@ mod core { // Similar to above. Some magic to make core testable. #[cfg(test)] mod std { - use std; + use std(vers = "0.2"); import std::test; } diff --git a/src/librustsyntax/ext/simplext.rs b/src/librustsyntax/ext/simplext.rs index dfc7d5314fc..70bec007e17 100644 --- a/src/librustsyntax/ext/simplext.rs +++ b/src/librustsyntax/ext/simplext.rs @@ -1,5 +1,3 @@ -use std; - import codemap::span; import std::map::{hashmap, str_hash}; diff --git a/src/librustsyntax/rustsyntax.rc b/src/librustsyntax/rustsyntax.rc index 51b5ef1c32c..101c08bd087 100644 --- a/src/librustsyntax/rustsyntax.rc +++ b/src/librustsyntax/rustsyntax.rc @@ -4,7 +4,12 @@ #[crate_type = "lib"]; -use std; +#[no_core]; + +use core(vers = "0.2"); +use std(vers = "0.2"); + +import core::*; mod attr; mod diagnostic; diff --git a/src/libstd/std.rc b/src/libstd/std.rc index 43b61e195e2..072ad5e25ac 100644 --- a/src/libstd/std.rc +++ b/src/libstd/std.rc @@ -8,6 +8,11 @@ #[crate_type = "lib"]; #[doc = "The Rust standard library"]; +#[no_core]; + +use core(vers = "0.2"); +import core::*; + export net, uv; export c_vec, four, tri, util; export bitv, deque, fun_treemap, list, map, smallintmap, sort, treemap, ufind; @@ -15,7 +20,6 @@ export rope, arena; export ebml, dbg, getopts, json, rand, sha1, term, time, prettyprint; export test, tempfile, serialization; - // General io and system-services modules mod net; diff --git a/src/rustc/driver/rustc.rs b/src/rustc/driver/rustc.rs index fe5587e0faf..dc3386acb73 100644 --- a/src/rustc/driver/rustc.rs +++ b/src/rustc/driver/rustc.rs @@ -1,5 +1,10 @@ -use std; -use rustc; +#[no_core]; + +use core(vers = "0.2"); +use std(vers = "0.2"); +use rustc(vers = "0.2"); + +import core::*; // -*- rust -*- import result::{ok, err}; diff --git a/src/rustc/rustc.rc b/src/rustc/rustc.rc index 5a19efb005b..a76133b4c82 100644 --- a/src/rustc/rustc.rc +++ b/src/rustc/rustc.rc @@ -9,11 +9,13 @@ #[license = "MIT"]; #[crate_type = "lib"]; -use std (name = "std", - vers = "0.2", - url = "https://github.com/mozilla/rust/tree/master/src/libstd"); +#[no_core]; -use rustsyntax; +use core(vers = "0.2"); +use std(vers = "0.2"); +use rustsyntax(vers = "0.2"); + +import core::*; mod middle { mod trans { diff --git a/src/rustdoc/rustdoc.rc b/src/rustdoc/rustdoc.rc index f7aed2df287..e910d33f3a8 100644 --- a/src/rustdoc/rustdoc.rc +++ b/src/rustdoc/rustdoc.rc @@ -9,8 +9,13 @@ #[license = "MIT"]; #[crate_type = "bin"]; -use std; -use rustc; +#[no_core]; + +use core(vers = "0.2"); +use std(vers = "0.2"); +use rustc(vers = "0.2"); + +import core::*; mod config; mod parse;