about summary refs log tree commit diff
path: root/src/libsyntax/ext/source_util.rs
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2015-01-06 11:07:09 -0800
committerAlex Crichton <alex@alexcrichton.com>2015-01-07 12:56:16 -0800
commit209c701bf9e95542aec69455bc12c7ca295109c4 (patch)
tree6091a9d7a271b6c1c3bbe7c782298975e1b07140 /src/libsyntax/ext/source_util.rs
parent9e4e524e0eb17c8f463e731f23b544003e8709c6 (diff)
downloadrust-209c701bf9e95542aec69455bc12c7ca295109c4.tar.gz
rust-209c701bf9e95542aec69455bc12c7ca295109c4.zip
std: Stablize the macros module
This commit performs a pass over the `std::macros` module, applying stability
attributes where necessary. In particular, this audits macros for patterns such
as:

* Standard use of forward-to-format-args via `$($arg:tt)*` (or `+`)
* Prevent macro-defined identifiers from leaking into expression arguments as
  hygiene is not perfectly implemented.
* Wherever possible, `$crate` is used now.

Specifically, the following actions were taken:

* The `std::macros` module itself is no longer public.
* The `panic!` macro is stable
* The `assert!` macro is stable
* The `assert_eq!` macro is stable
* The `debug_assert!` macro is stable
* The `debug_assert_eq!` macro is stable
* The `unreachable!` macro is stable after removing the extra forms to bring the
  definition in line with the `unimplemented!` macro.
* The `try!` macro is stable
* The `vec!` macro is stable

[breaking-change]
Diffstat (limited to 'src/libsyntax/ext/source_util.rs')
-rw-r--r--src/libsyntax/ext/source_util.rs6
1 files changed, 0 insertions, 6 deletions
diff --git a/src/libsyntax/ext/source_util.rs b/src/libsyntax/ext/source_util.rs
index 1ba91dd371c..8021474c1be 100644
--- a/src/libsyntax/ext/source_util.rs
+++ b/src/libsyntax/ext/source_util.rs
@@ -161,12 +161,6 @@ pub fn expand_include_str(cx: &mut ExtCtxt, sp: Span, tts: &[ast::TokenTree])
     }
 }
 
-pub fn expand_include_bin(cx: &mut ExtCtxt, sp: Span, tts: &[ast::TokenTree])
-                          -> Box<base::MacResult+'static> {
-    cx.span_warn(sp, "include_bin! is deprecated; use include_bytes! instead");
-    expand_include_bytes(cx, sp, tts)
-}
-
 pub fn expand_include_bytes(cx: &mut ExtCtxt, sp: Span, tts: &[ast::TokenTree])
                             -> Box<base::MacResult+'static> {
     let file = match get_single_str_from_tts(cx, sp, tts, "include_bytes!") {