diff options
| author | bors <bors@rust-lang.org> | 2024-05-07 12:40:20 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-05-07 12:40:20 +0000 |
| commit | cc8d9b692720c7d15445024485c4bbfce35dbce6 (patch) | |
| tree | 51f008fac39304ce127f24ca9c9cc430a76aecc7 | |
| parent | 14081a255d005109bc6260dc0e748c8e860e77a0 (diff) | |
| parent | 3488679768d8dff17905f69bf6413fc259004a3f (diff) | |
| download | rust-cc8d9b692720c7d15445024485c4bbfce35dbce6.tar.gz rust-cc8d9b692720c7d15445024485c4bbfce35dbce6.zip | |
Auto merge of #124836 - tgross35:const-slice-last-chunk, r=BurntSushi
Correct the const stabilization of `last_chunk` for slices `<[T]>::last_chunk` should have become const stable as part of <https://github.com/rust-lang/rust/pull/117561>. Update the const stability gate to reflect this.
| -rw-r--r-- | library/core/src/slice/mod.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/library/core/src/slice/mod.rs b/library/core/src/slice/mod.rs index ed7bcec89b9..133cde8c097 100644 --- a/library/core/src/slice/mod.rs +++ b/library/core/src/slice/mod.rs @@ -544,7 +544,7 @@ impl<T> [T] { /// ``` #[inline] #[stable(feature = "slice_first_last_chunk", since = "1.77.0")] - #[rustc_const_unstable(feature = "const_slice_first_last_chunk", issue = "111774")] + #[rustc_const_stable(feature = "slice_first_last_chunk", since = "1.77.0")] pub const fn last_chunk<const N: usize>(&self) -> Option<&[T; N]> { if self.len() < N { None |
