diff options
| author | bors <bors@rust-lang.org> | 2015-07-30 18:42:32 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2015-07-30 18:42:32 +0000 |
| commit | 6edc994021a6bb1922ef77f62841f01a7bdf235d (patch) | |
| tree | b2b212bf9cbd4b24849d7774cdb3f1d97d7d2420 /src/libstd/lib.rs | |
| parent | 28869d45dd1d3ba04e17dec82408f9f3c548e776 (diff) | |
| parent | 5af6cf9fa422cb492525e139752a57d2d89f42c7 (diff) | |
| download | rust-6edc994021a6bb1922ef77f62841f01a7bdf235d.tar.gz rust-6edc994021a6bb1922ef77f62841f01a7bdf235d.zip | |
Auto merge of #27388 - alexcrichton:remove-curious-inner, r=brson
This isn't actually necessary any more with the advent of `$crate` and changes in the compiler to expand macros to `::core::$foo` in the context of a `#![no_std]` crate. The libcore inner module was also trimmed down a bit to the bare bones.
Diffstat (limited to 'src/libstd/lib.rs')
| -rw-r--r-- | src/libstd/lib.rs | 27 |
1 files changed, 5 insertions, 22 deletions
diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs index 16491549705..61de7eafbb5 100644 --- a/src/libstd/lib.rs +++ b/src/libstd/lib.rs @@ -416,27 +416,10 @@ pub mod __rand { // because rustdoc only looks for these modules at the crate level. include!("primitive_docs.rs"); -// A curious inner-module that's not exported that contains the binding -// 'std' so that macro-expanded references to std::error and such -// can be resolved within libstd. -#[doc(hidden)] +// The expansion of --test has a few references to `::std::$foo` so this module +// is necessary to get things to compile. +#[cfg(test)] mod std { - pub use sync; // used for select!() - pub use error; // used for try!() - pub use fmt; // used for any formatting strings - pub use option; // used for thread_local!{} - pub use rt; // used for panic!() - pub use vec; // used for vec![] - pub use cell; // used for tls! - pub use thread; // used for thread_local! - pub use marker; // used for tls! - - // The test runner calls ::std::env::args() but really wants realstd - #[cfg(test)] pub use realstd::env as env; - // The test runner requires std::slice::Vector, so re-export std::slice just for it. - // - // It is also used in vec![] - pub use slice; - - pub use boxed; // used for vec![] + pub use option; + pub use realstd::env; } |
