From 7d268119f07aeb41a1abe093c3fd2434743ac228 Mon Sep 17 00:00:00 2001 From: Mark Mansi Date: Wed, 18 Dec 2019 12:04:47 -0600 Subject: [PATCH] no need to bootstrap --- src/liballoc/lib.rs | 2 +- src/liballoc/raw_vec.rs | 9 +-------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/src/liballoc/lib.rs b/src/liballoc/lib.rs index 6e44c7631b3..be46e632be4 100644 --- a/src/liballoc/lib.rs +++ b/src/liballoc/lib.rs @@ -85,7 +85,7 @@ #![feature(const_generic_impls_guard)] #![feature(const_generics)] #![feature(const_in_array_repeat_expressions)] -#![cfg_attr(not(bootstrap), feature(const_if_match))] +#![feature(const_if_match)] #![feature(cow_is_borrowed)] #![feature(dispatch_from_dyn)] #![feature(core_intrinsics)] diff --git a/src/liballoc/raw_vec.rs b/src/liballoc/raw_vec.rs index 96de5185b88..3201c702abb 100644 --- a/src/liballoc/raw_vec.rs +++ b/src/liballoc/raw_vec.rs @@ -52,14 +52,7 @@ impl RawVec { /// Like `new`, but parameterized over the choice of allocator for /// the returned `RawVec`. pub const fn new_in(a: A) -> Self { - // FIXME(mark-i-m): remove bootstrapping cfgs these after a cycle - let cap = { - #[cfg(not(bootstrap))] - { if mem::size_of::() == 0 { core::usize::MAX } else { 0 } } - - #[cfg(bootstrap)] - [0, !0][(mem::size_of::() == 0) as usize] - }; + let cap = if mem::size_of::() == 0 { core::usize::MAX } else { 0 }; // `Unique::empty()` doubles as "unallocated" and "zero-sized allocation". RawVec {