diff options
Diffstat (limited to 'src/liballoc')
| -rw-r--r-- | src/liballoc/lib.rs | 1 | ||||
| -rw-r--r-- | src/liballoc/raw_vec.rs | 3 |
2 files changed, 1 insertions, 3 deletions
diff --git a/src/liballoc/lib.rs b/src/liballoc/lib.rs index ffa0ec4917c..0a232ed0620 100644 --- a/src/liballoc/lib.rs +++ b/src/liballoc/lib.rs @@ -78,7 +78,6 @@ #![feature(custom_attribute)] #![feature(fundamental)] #![feature(lang_items)] -#![feature(num_bits_bytes)] #![feature(optin_builtin_traits)] #![feature(placement_in_syntax)] #![feature(placement_new_protocol)] diff --git a/src/liballoc/raw_vec.rs b/src/liballoc/raw_vec.rs index 52bd62f7a66..c407cef25e7 100644 --- a/src/liballoc/raw_vec.rs +++ b/src/liballoc/raw_vec.rs @@ -16,7 +16,6 @@ use super::oom; use super::boxed::Box; use core::ops::Drop; use core::cmp; -use core; /// A low-level utility for more ergonomically allocating, reallocating, and deallocating a /// a buffer of memory on the heap without having to worry about all the corner cases @@ -584,7 +583,7 @@ impl<T> Drop for RawVec<T> { #[inline] fn alloc_guard(alloc_size: usize) { - if core::usize::BITS < 64 { + if mem::size_of::<usize>() < 8 { assert!(alloc_size <= ::core::isize::MAX as usize, "capacity overflow"); } |
