We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Vec::leak
1 parent 76a49ef commit 5350164Copy full SHA for 5350164
src/liballoc/vec.rs
@@ -1512,14 +1512,12 @@ impl<T> Vec<T> {
1512
/// Simple usage:
1513
///
1514
/// ```
1515
- /// #![feature(vec_leak)]
1516
- ///
1517
/// let x = vec![1, 2, 3];
1518
/// let static_ref: &'static mut [usize] = x.leak();
1519
/// static_ref[0] += 1;
1520
/// assert_eq!(static_ref, &[2, 2, 3]);
1521
1522
- #[unstable(feature = "vec_leak", issue = "62195")]
+ #[stable(feature = "vec_leak", since = "1.47.0")]
1523
#[inline]
1524
pub fn leak<'a>(self) -> &'a mut [T]
1525
where
0 commit comments