From 74a6d1c821a37a407d2b2bc701d62d0b460b9215 Mon Sep 17 00:00:00 2001 From: Vadim Petrochenkov Date: Sat, 8 Jun 2019 11:36:30 +0300 Subject: Turn `#[allocator]` into a built-in attribute and rename it to `#[rustc_allocator]` --- src/liballoc/alloc.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/liballoc/alloc.rs') diff --git a/src/liballoc/alloc.rs b/src/liballoc/alloc.rs index 41ff06d70ff..755feb84962 100644 --- a/src/liballoc/alloc.rs +++ b/src/liballoc/alloc.rs @@ -15,7 +15,8 @@ extern "Rust" { // them from the `#[global_allocator]` attribute if there is one, or uses the // default implementations in libstd (`__rdl_alloc` etc in `src/libstd/alloc.rs`) // otherwise. - #[allocator] + #[cfg_attr(bootstrap, allocator)] + #[cfg_attr(not(bootstrap), rustc_allocator)] #[rustc_allocator_nounwind] fn __rust_alloc(size: usize, align: usize) -> *mut u8; #[rustc_allocator_nounwind] -- cgit 1.4.1-3-g733a5