Skip to content

Commit 83b1a94

Browse files
authored
Rollup merge of #93016 - Amanieu:vec_spare_capacity, r=Mark-Simulacrum
Stabilize vec_spare_capacity Closes #75017
2 parents b8c544d + e012b9a commit 83b1a94

File tree

5 files changed

+4
-8
lines changed

5 files changed

+4
-8
lines changed

library/alloc/src/vec/mod.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -2051,8 +2051,6 @@ impl<T, A: Allocator> Vec<T, A> {
20512051
/// # Examples
20522052
///
20532053
/// ```
2054-
/// #![feature(vec_spare_capacity)]
2055-
///
20562054
/// // Allocate vector big enough for 10 elements.
20572055
/// let mut v = Vec::with_capacity(10);
20582056
///
@@ -2069,7 +2067,7 @@ impl<T, A: Allocator> Vec<T, A> {
20692067
///
20702068
/// assert_eq!(&v, &[0, 1, 2]);
20712069
/// ```
2072-
#[unstable(feature = "vec_spare_capacity", issue = "75017")]
2070+
#[stable(feature = "vec_spare_capacity", since = "1.60.0")]
20732071
#[inline]
20742072
pub fn spare_capacity_mut(&mut self) -> &mut [MaybeUninit<T>] {
20752073
// Note:

library/alloc/tests/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@
3131
#![feature(iter_advance_by)]
3232
#![feature(slice_group_by)]
3333
#![feature(slice_partition_dedup)]
34-
#![feature(vec_spare_capacity)]
3534
#![feature(string_remove_matches)]
3635
#![feature(const_btree_new)]
3736
#![feature(const_default_impls)]

library/core/src/mem/maybe_uninit.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1038,7 +1038,7 @@ impl<T> MaybeUninit<T> {
10381038
/// ```
10391039
///
10401040
/// ```
1041-
/// #![feature(maybe_uninit_write_slice, vec_spare_capacity)]
1041+
/// #![feature(maybe_uninit_write_slice)]
10421042
/// use std::mem::MaybeUninit;
10431043
///
10441044
/// let mut vec = Vec::with_capacity(32);
@@ -1098,7 +1098,7 @@ impl<T> MaybeUninit<T> {
10981098
/// ```
10991099
///
11001100
/// ```
1101-
/// #![feature(maybe_uninit_write_slice, vec_spare_capacity)]
1101+
/// #![feature(maybe_uninit_write_slice)]
11021102
/// use std::mem::MaybeUninit;
11031103
///
11041104
/// let mut vec = Vec::with_capacity(32);

library/std/src/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,6 @@
340340
#![feature(unboxed_closures)]
341341
#![feature(unwrap_infallible)]
342342
#![feature(vec_into_raw_parts)]
343-
#![feature(vec_spare_capacity)]
344343
// NB: the above list is sorted to minimize merge conflicts.
345344
#![default_lib_allocator]
346345

library/stdarch

0 commit comments

Comments
 (0)