diff options
| author | Chris Wong <lambda.fairy@gmail.com> | 2014-12-22 10:57:09 +1300 |
|---|---|---|
| committer | Chris Wong <lambda.fairy@gmail.com> | 2014-12-23 22:06:32 +1300 |
| commit | 85c1a4b1ba09dae786b3554e0ab596814efabe0e (patch) | |
| tree | 361dd0205510de3ea787361683a12de74efb9400 /src/libsyntax/ext/base.rs | |
| parent | 62fb41c32bd97c4e9bc286a1db5d7126a06b8b91 (diff) | |
| download | rust-85c1a4b1ba09dae786b3554e0ab596814efabe0e.tar.gz rust-85c1a4b1ba09dae786b3554e0ab596814efabe0e.zip | |
Rename include_bin! to include_bytes!
According to [RFC 344][], methods that return `&[u8]` should have names ending in `bytes`. Though `include_bin!` is a macro not a method, it seems reasonable to follow the convention anyway. We keep the old name around for now, but trigger a deprecation warning when it is used. [RFC 344]: https://github.com/rust-lang/rfcs/blob/master/text/0344-conventions-galore.md [breaking-change]
Diffstat (limited to 'src/libsyntax/ext/base.rs')
| -rw-r--r-- | src/libsyntax/ext/base.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libsyntax/ext/base.rs b/src/libsyntax/ext/base.rs index d45871708dc..8e69076a2c5 100644 --- a/src/libsyntax/ext/base.rs +++ b/src/libsyntax/ext/base.rs @@ -442,6 +442,9 @@ fn initial_syntax_expander_table(ecfg: &expand::ExpansionConfig) -> SyntaxEnv { syntax_expanders.insert(intern("include_bin"), builtin_normal_expander( ext::source_util::expand_include_bin)); + syntax_expanders.insert(intern("include_bytes"), + builtin_normal_expander( + ext::source_util::expand_include_bytes)); syntax_expanders.insert(intern("module_path"), builtin_normal_expander( ext::source_util::expand_mod)); |
