Vec::new is const tstable in 1.39 not 1.32

This commit is contained in:
Christopher Durham 2020-03-09 23:07:04 -04:00 committed by GitHub
parent 3dbade652e
commit a56196205b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -317,7 +317,7 @@ impl<T> Vec<T> {
/// let mut vec: Vec<i32> = Vec::new();
/// ```
#[inline]
#[rustc_const_stable(feature = "const_vec_new", since = "1.32.0")]
#[rustc_const_stable(feature = "const_vec_new", since = "1.39.0")]
#[stable(feature = "rust1", since = "1.0.0")]
pub const fn new() -> Vec<T> {
Vec { buf: RawVec::NEW, len: 0 }