about summary refs log tree commit diff
diff options
context:
space:
mode:
authorKeegan McAllister <kmcallister@mozilla.com>2014-12-18 20:09:57 -0800
committerKeegan McAllister <kmcallister@mozilla.com>2015-01-05 12:00:57 -0800
commitfc584793237c388e9dca76ef406d1af34e453fe2 (patch)
tree9b8116de6b62341df1fee3edb56368b35d984fd3
parent73806ddd0fd91066d7b903a00a080cbadcc04311 (diff)
downloadrust-fc584793237c388e9dca76ef406d1af34e453fe2.tar.gz
rust-fc584793237c388e9dca76ef406d1af34e453fe2.zip
Stop using macro_escape as an inner attribute
In preparation for the rename.
-rw-r--r--src/libcollections/lib.rs1
-rw-r--r--src/libcollections/macros.rs2
-rw-r--r--src/libcore/lib.rs15
-rw-r--r--src/libcore/macros.rs2
-rw-r--r--src/libcore/num/float_macros.rs1
-rw-r--r--src/libcore/num/int_macros.rs1
-rw-r--r--src/libcore/num/uint_macros.rs1
-rw-r--r--src/libcoretest/num/int_macros.rs2
-rw-r--r--src/libcoretest/num/mod.rs5
-rw-r--r--src/libcoretest/num/uint_macros.rs2
-rw-r--r--src/liblog/lib.rs2
-rw-r--r--src/liblog/macros.rs2
-rw-r--r--src/librustc/lint/mod.rs2
-rw-r--r--src/librustc_trans/trans/macros.rs2
-rw-r--r--src/librustc_trans/trans/mod.rs4
-rw-r--r--src/librustdoc/lib.rs5
-rw-r--r--src/libstd/bitflags.rs1
-rw-r--r--src/libstd/io/mod.rs4
-rw-r--r--src/libstd/io/test.rs2
-rw-r--r--src/libstd/lib.rs27
-rw-r--r--src/libstd/macros.rs1
-rw-r--r--src/libstd/macros_stage0.rs1
-rw-r--r--src/libstd/num/float_macros.rs1
-rw-r--r--src/libstd/num/int_macros.rs1
-rw-r--r--src/libstd/num/uint_macros.rs1
-rw-r--r--src/libstd/rt/macros.rs2
-rw-r--r--src/libstd/thread_local/mod.rs2
-rw-r--r--src/libstd/thread_local/scoped.rs1
-rw-r--r--src/libsyntax/diagnostics/macros.rs2
-rw-r--r--src/libsyntax/parse/mod.rs4
-rw-r--r--src/libsyntax/parse/parser.rs2
-rw-r--r--src/test/auxiliary/lint_stability.rs1
32 files changed, 55 insertions, 47 deletions
diff --git a/src/libcollections/lib.rs b/src/libcollections/lib.rs
index 27ab791b604..9214ec7e65b 100644
--- a/src/libcollections/lib.rs
+++ b/src/libcollections/lib.rs
@@ -54,6 +54,7 @@ pub use vec_map::VecMap;
 // Needed for the vec! macro
 pub use alloc::boxed;
 
+#[macro_escape]
 mod macros;
 
 pub mod binary_heap;
diff --git a/src/libcollections/macros.rs b/src/libcollections/macros.rs
index 0dbc71269a6..0c5929e8661 100644
--- a/src/libcollections/macros.rs
+++ b/src/libcollections/macros.rs
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
-
 /// Creates a `std::vec::Vec` containing the arguments.
 // NOTE: remove after the next snapshot
 #[cfg(stage0)]
diff --git a/src/libcore/lib.rs b/src/libcore/lib.rs
index 0cda2e4a9c6..588421dfa10 100644
--- a/src/libcore/lib.rs
+++ b/src/libcore/lib.rs
@@ -62,11 +62,20 @@
 #![feature(default_type_params, unboxed_closures, associated_types)]
 #![deny(missing_docs)]
 
+#[macro_escape]
 mod macros;
 
-#[path = "num/float_macros.rs"] mod float_macros;
-#[path = "num/int_macros.rs"]   mod int_macros;
-#[path = "num/uint_macros.rs"]  mod uint_macros;
+#[path = "num/float_macros.rs"]
+#[macro_escape]
+mod float_macros;
+
+#[path = "num/int_macros.rs"]
+#[macro_escape]
+mod int_macros;
+
+#[path = "num/uint_macros.rs"]
+#[macro_escape]
+mod uint_macros;
 
 #[path = "num/int.rs"]  pub mod int;
 #[path = "num/i8.rs"]   pub mod i8;
diff --git a/src/libcore/macros.rs b/src/libcore/macros.rs
index 3b21a68a292..a579f9db416 100644
--- a/src/libcore/macros.rs
+++ b/src/libcore/macros.rs
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
-
 /// Entry point of task panic, for details, see std::macros
 #[macro_export]
 macro_rules! panic {
diff --git a/src/libcore/num/float_macros.rs b/src/libcore/num/float_macros.rs
index 97de61d7e27..20300d29fa0 100644
--- a/src/libcore/num/float_macros.rs
+++ b/src/libcore/num/float_macros.rs
@@ -8,7 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
 #![doc(hidden)]
 
 macro_rules! assert_approx_eq {
diff --git a/src/libcore/num/int_macros.rs b/src/libcore/num/int_macros.rs
index 522eab9180c..61cd8cbf7c1 100644
--- a/src/libcore/num/int_macros.rs
+++ b/src/libcore/num/int_macros.rs
@@ -8,7 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
 #![doc(hidden)]
 
 macro_rules! int_module { ($T:ty, $bits:expr) => (
diff --git a/src/libcore/num/uint_macros.rs b/src/libcore/num/uint_macros.rs
index 82eca0d4659..535765840a0 100644
--- a/src/libcore/num/uint_macros.rs
+++ b/src/libcore/num/uint_macros.rs
@@ -8,7 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
 #![doc(hidden)]
 
 macro_rules! uint_module { ($T:ty, $T_SIGNED:ty, $bits:expr) => (
diff --git a/src/libcoretest/num/int_macros.rs b/src/libcoretest/num/int_macros.rs
index 8885d3a5208..965ffde7097 100644
--- a/src/libcoretest/num/int_macros.rs
+++ b/src/libcoretest/num/int_macros.rs
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
-
 macro_rules! int_module (($T:ty, $T_i:ident) => (
 #[cfg(test)]
 mod tests {
diff --git a/src/libcoretest/num/mod.rs b/src/libcoretest/num/mod.rs
index 651e8640e91..01868675c76 100644
--- a/src/libcoretest/num/mod.rs
+++ b/src/libcoretest/num/mod.rs
@@ -14,13 +14,18 @@ use core::num::{NumCast, cast};
 use core::ops::{Add, Sub, Mul, Div, Rem};
 use core::kinds::Copy;
 
+#[macro_escape]
 mod int_macros;
+
 mod i8;
 mod i16;
 mod i32;
 mod i64;
 mod int;
+
+#[macro_escape]
 mod uint_macros;
+
 mod u8;
 mod u16;
 mod u32;
diff --git a/src/libcoretest/num/uint_macros.rs b/src/libcoretest/num/uint_macros.rs
index 2311c19d557..eff238c816e 100644
--- a/src/libcoretest/num/uint_macros.rs
+++ b/src/libcoretest/num/uint_macros.rs
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
-
 macro_rules! uint_module (($T:ty, $T_i:ident) => (
 #[cfg(test)]
 mod tests {
diff --git a/src/liblog/lib.rs b/src/liblog/lib.rs
index 0508402ff19..61523c6fd0f 100644
--- a/src/liblog/lib.rs
+++ b/src/liblog/lib.rs
@@ -183,7 +183,9 @@ use regex::Regex;
 
 use directive::LOG_LEVEL_NAMES;
 
+#[macro_escape]
 pub mod macros;
+
 mod directive;
 
 /// Maximum logging level of a module that can be specified. Common logging
diff --git a/src/liblog/macros.rs b/src/liblog/macros.rs
index 233d1c049f4..66682dba7b6 100644
--- a/src/liblog/macros.rs
+++ b/src/liblog/macros.rs
@@ -10,8 +10,6 @@
 
 //! Logging macros
 
-#![macro_escape]
-
 /// The standard logging macro
 ///
 /// This macro will generically log over a provided level (of type u32) with a
diff --git a/src/librustc/lint/mod.rs b/src/librustc/lint/mod.rs
index 461a67ba937..e9778fa05ff 100644
--- a/src/librustc/lint/mod.rs
+++ b/src/librustc/lint/mod.rs
@@ -28,8 +28,6 @@
 //! example) requires more effort. See `emit_lint` and `GatherNodeLevels`
 //! in `context.rs`.
 
-#![macro_escape]
-
 pub use self::Level::*;
 pub use self::LintSource::*;
 
diff --git a/src/librustc_trans/trans/macros.rs b/src/librustc_trans/trans/macros.rs
index ab202975bfc..77efcc6fb00 100644
--- a/src/librustc_trans/trans/macros.rs
+++ b/src/librustc_trans/trans/macros.rs
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
-
 macro_rules! unpack_datum {
     ($bcx: ident, $inp: expr) => (
         {
diff --git a/src/librustc_trans/trans/mod.rs b/src/librustc_trans/trans/mod.rs
index 72c4def15a2..9b7f282f8bb 100644
--- a/src/librustc_trans/trans/mod.rs
+++ b/src/librustc_trans/trans/mod.rs
@@ -16,8 +16,10 @@ pub use self::base::trans_crate;
 pub use self::context::CrateContext;
 pub use self::common::gensym_name;
 
-mod doc;
+#[macro_escape]
 mod macros;
+
+mod doc;
 mod inline;
 mod monomorphize;
 mod controlflow;
diff --git a/src/librustdoc/lib.rs b/src/librustdoc/lib.rs
index 106fe452f46..a454760c8b5 100644
--- a/src/librustdoc/lib.rs
+++ b/src/librustdoc/lib.rs
@@ -49,11 +49,12 @@ use rustc::session::search_paths::SearchPaths;
 // reexported from `clean` so it can be easily updated with the mod itself
 pub use clean::SCHEMA_VERSION;
 
+#[macro_escape]
+pub mod externalfiles;
+
 pub mod clean;
 pub mod core;
 pub mod doctree;
-#[macro_escape]
-pub mod externalfiles;
 pub mod fold;
 pub mod html {
     pub mod highlight;
diff --git a/src/libstd/bitflags.rs b/src/libstd/bitflags.rs
index 65cbce08543..ed3f2cbe1a1 100644
--- a/src/libstd/bitflags.rs
+++ b/src/libstd/bitflags.rs
@@ -9,7 +9,6 @@
 // except according to those terms.
 
 #![experimental]
-#![macro_escape]
 
 //! A typesafe bitmask flag generator.
 
diff --git a/src/libstd/io/mod.rs b/src/libstd/io/mod.rs
index 3fa0b5645c5..bf373a145e4 100644
--- a/src/libstd/io/mod.rs
+++ b/src/libstd/io/mod.rs
@@ -282,10 +282,12 @@ pub mod net;
 pub mod pipe;
 pub mod process;
 pub mod stdio;
-pub mod test;
 pub mod timer;
 pub mod util;
 
+#[macro_escape]
+pub mod test;
+
 /// The default buffer size for various I/O operations
 // libuv recommends 64k buffers to maximize throughput
 // https://groups.google.com/forum/#!topic/libuv/oQO1HJAIDdA
diff --git a/src/libstd/io/test.rs b/src/libstd/io/test.rs
index 3ce56c907b3..6eeef175f73 100644
--- a/src/libstd/io/test.rs
+++ b/src/libstd/io/test.rs
@@ -10,8 +10,6 @@
 
 //! Various utility functions useful for writing I/O tests
 
-#![macro_escape]
-
 use prelude::v1::*;
 
 use libc;
diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs
index eba90d39b4a..5ffd3ebc7ad 100644
--- a/src/libstd/lib.rs
+++ b/src/libstd/lib.rs
@@ -172,8 +172,15 @@ pub use unicode::char;
 
 /* Exported macros */
 
-#[cfg(stage0)] pub mod macros_stage0;
-#[cfg(not(stage0))] pub mod macros;
+#[cfg(stage0)]
+#[macro_escape]
+pub mod macros_stage0;
+
+#[cfg(not(stage0))]
+#[macro_escape]
+pub mod macros;
+
+#[macro_escape]
 pub mod bitflags;
 
 mod rtdeps;
@@ -185,9 +192,17 @@ pub mod prelude;
 
 /* Primitive types */
 
-#[path = "num/float_macros.rs"] mod float_macros;
-#[path = "num/int_macros.rs"]   mod int_macros;
-#[path = "num/uint_macros.rs"]  mod uint_macros;
+#[path = "num/float_macros.rs"]
+#[macro_escape]
+mod float_macros;
+
+#[path = "num/int_macros.rs"]
+#[macro_escape]
+mod int_macros;
+
+#[path = "num/uint_macros.rs"]
+#[macro_escape]
+mod uint_macros;
 
 #[path = "num/int.rs"]  pub mod int;
 #[path = "num/i8.rs"]   pub mod i8;
@@ -214,7 +229,9 @@ pub mod num;
 
 /* Runtime and platform support */
 
+#[macro_escape]
 pub mod thread_local;
+
 pub mod c_str;
 pub mod c_vec;
 pub mod dynamic_lib;
diff --git a/src/libstd/macros.rs b/src/libstd/macros.rs
index e833acb968d..6bf1ba2355f 100644
--- a/src/libstd/macros.rs
+++ b/src/libstd/macros.rs
@@ -15,7 +15,6 @@
 //! library.
 
 #![experimental]
-#![macro_escape]
 
 /// The entry point for panic of Rust tasks.
 ///
diff --git a/src/libstd/macros_stage0.rs b/src/libstd/macros_stage0.rs
index 63fd3209cc0..48d62e73e13 100644
--- a/src/libstd/macros_stage0.rs
+++ b/src/libstd/macros_stage0.rs
@@ -15,7 +15,6 @@
 //! library.
 
 #![experimental]
-#![macro_escape]
 
 /// The entry point for panic of Rust tasks.
 ///
diff --git a/src/libstd/num/float_macros.rs b/src/libstd/num/float_macros.rs
index fd00f15662a..4c52f29b12d 100644
--- a/src/libstd/num/float_macros.rs
+++ b/src/libstd/num/float_macros.rs
@@ -9,7 +9,6 @@
 // except according to those terms.
 
 #![experimental]
-#![macro_escape]
 #![doc(hidden)]
 
 macro_rules! assert_approx_eq {
diff --git a/src/libstd/num/int_macros.rs b/src/libstd/num/int_macros.rs
index fce150c4ad1..ebcb2086187 100644
--- a/src/libstd/num/int_macros.rs
+++ b/src/libstd/num/int_macros.rs
@@ -9,7 +9,6 @@
 // except according to those terms.
 
 #![experimental]
-#![macro_escape]
 #![doc(hidden)]
 
 macro_rules! int_module { ($T:ty) => (
diff --git a/src/libstd/num/uint_macros.rs b/src/libstd/num/uint_macros.rs
index 7818f4a0534..08ea1b024c9 100644
--- a/src/libstd/num/uint_macros.rs
+++ b/src/libstd/num/uint_macros.rs
@@ -9,7 +9,6 @@
 // except according to those terms.
 
 #![experimental]
-#![macro_escape]
 #![doc(hidden)]
 #![allow(unsigned_negation)]
 
diff --git a/src/libstd/rt/macros.rs b/src/libstd/rt/macros.rs
index 0f35500a04a..bbc96d0b19f 100644
--- a/src/libstd/rt/macros.rs
+++ b/src/libstd/rt/macros.rs
@@ -13,8 +13,6 @@
 //! These macros call functions which are only accessible in the `rt` module, so
 //! they aren't defined anywhere outside of the `rt` module.
 
-#![macro_escape]
-
 macro_rules! rterrln {
     ($fmt:expr $($arg:tt)*) => ( {
         ::rt::util::dumb_print(format_args!(concat!($fmt, "\n") $($arg)*))
diff --git a/src/libstd/thread_local/mod.rs b/src/libstd/thread_local/mod.rs
index d3b4fab9681..1ed01c034b5 100644
--- a/src/libstd/thread_local/mod.rs
+++ b/src/libstd/thread_local/mod.rs
@@ -34,13 +34,13 @@
 //! will want to make use of some form of **interior mutability** through the
 //! `Cell` or `RefCell` types.
 
-#![macro_escape]
 #![stable]
 
 use prelude::v1::*;
 
 use cell::UnsafeCell;
 
+#[macro_escape]
 pub mod scoped;
 
 // Sure wish we had macro hygiene, no?
diff --git a/src/libstd/thread_local/scoped.rs b/src/libstd/thread_local/scoped.rs
index dc36fda3a02..714b71d5dbd 100644
--- a/src/libstd/thread_local/scoped.rs
+++ b/src/libstd/thread_local/scoped.rs
@@ -38,7 +38,6 @@
 //! });
 //! ```
 
-#![macro_escape]
 #![unstable = "scoped TLS has yet to have wide enough use to fully consider \
                stabilizing its interface"]
 
diff --git a/src/libsyntax/diagnostics/macros.rs b/src/libsyntax/diagnostics/macros.rs
index 3107508a96a..34a193dffd3 100644
--- a/src/libsyntax/diagnostics/macros.rs
+++ b/src/libsyntax/diagnostics/macros.rs
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
-
 #[macro_export]
 macro_rules! register_diagnostic {
     ($code:tt, $description:tt) => (__register_diagnostic! { $code, $description });
diff --git a/src/libsyntax/parse/mod.rs b/src/libsyntax/parse/mod.rs
index 3e4f2c8d4e2..05ed535ee36 100644
--- a/src/libsyntax/parse/mod.rs
+++ b/src/libsyntax/parse/mod.rs
@@ -24,8 +24,10 @@ use std::num::Int;
 use std::str;
 use std::iter;
 
-pub mod lexer;
+#[macro_escape]
 pub mod parser;
+
+pub mod lexer;
 pub mod token;
 pub mod attr;
 
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index 62bda20473f..5539abb16b4 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -8,8 +8,6 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-#![macro_escape]
-
 pub use self::PathParsingMode::*;
 use self::ItemOrViewItem::*;
 
diff --git a/src/test/auxiliary/lint_stability.rs b/src/test/auxiliary/lint_stability.rs
index 82af18b189b..5ef1acae6c7 100644
--- a/src/test/auxiliary/lint_stability.rs
+++ b/src/test/auxiliary/lint_stability.rs
@@ -11,7 +11,6 @@
 #![crate_type = "lib"]
 
 #![feature(macro_rules)]
-#![macro_escape]
 
 #[deprecated]
 pub fn deprecated() {}