diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2024-03-23 15:00:17 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-03-23 15:00:17 +0100 |
| commit | 71ce3c26e625b1af4b586ec291564d32a8eeb5f0 (patch) | |
| tree | b7d9ee0a263a749abdd80f9d6a208c4a727a8b7f | |
| parent | c3b05c6e5b5b59613350b8c2875b0add67ed74df (diff) | |
| parent | 67c03579bc45a280548499d37ba2db7ef2e9f6a3 (diff) | |
| download | rust-71ce3c26e625b1af4b586ec291564d32a8eeb5f0.tar.gz rust-71ce3c26e625b1af4b586ec291564d32a8eeb5f0.zip | |
Rollup merge of #120577 - wutchzone:slice_split_at_unchecked, r=m-ou-se
Stabilize slice_split_at_unchecked Greetings! I took the opportunity, and I tried to stabilize the `slice_split_at_unchecked` feature. I followed the guidelines, and I hope everything was done correctly :crossed_fingers: . Closes #76014
| -rw-r--r-- | library/core/src/lib.rs | 1 | ||||
| -rw-r--r-- | library/core/src/slice/mod.rs | 8 |
2 files changed, 2 insertions, 7 deletions
diff --git a/library/core/src/lib.rs b/library/core/src/lib.rs index 2718dd11473..aa54bb763bd 100644 --- a/library/core/src/lib.rs +++ b/library/core/src/lib.rs @@ -189,7 +189,6 @@ #![feature(ptr_metadata)] #![feature(set_ptr_value)] #![feature(slice_ptr_get)] -#![feature(slice_split_at_unchecked)] #![feature(split_at_checked)] #![feature(str_internals)] #![feature(str_split_inclusive_remainder)] diff --git a/library/core/src/slice/mod.rs b/library/core/src/slice/mod.rs index 4a574bf0347..a3a1d1d3bac 100644 --- a/library/core/src/slice/mod.rs +++ b/library/core/src/slice/mod.rs @@ -1944,8 +1944,6 @@ impl<T> [T] { /// # Examples /// /// ``` - /// #![feature(slice_split_at_unchecked)] - /// /// let v = [1, 2, 3, 4, 5, 6]; /// /// unsafe { @@ -1966,7 +1964,7 @@ impl<T> [T] { /// assert_eq!(right, []); /// } /// ``` - #[unstable(feature = "slice_split_at_unchecked", reason = "new API", issue = "76014")] + #[stable(feature = "slice_split_at_unchecked", since = "CURRENT_RUSTC_VERSION")] #[rustc_const_stable(feature = "const_slice_split_at_unchecked", since = "1.77.0")] #[inline] #[must_use] @@ -2008,8 +2006,6 @@ impl<T> [T] { /// # Examples /// /// ``` - /// #![feature(slice_split_at_unchecked)] - /// /// let mut v = [1, 0, 3, 0, 5, 6]; /// // scoped to restrict the lifetime of the borrows /// unsafe { @@ -2021,7 +2017,7 @@ impl<T> [T] { /// } /// assert_eq!(v, [1, 2, 3, 4, 5, 6]); /// ``` - #[unstable(feature = "slice_split_at_unchecked", reason = "new API", issue = "76014")] + #[stable(feature = "slice_split_at_unchecked", since = "CURRENT_RUSTC_VERSION")] #[rustc_const_unstable(feature = "const_slice_split_at_mut", issue = "101804")] #[inline] #[must_use] |
