@@ -353,7 +353,8 @@ impl<T> [T] {
353
353
/// ```
354
354
#[ inline]
355
355
#[ stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
356
- #[ rustc_const_unstable( feature = "const_slice_first_last_chunk" , issue = "111774" ) ]
356
+ #[ rustc_const_stable( feature = "const_slice_first_last_chunk" , since = "CURRENT_RUSTC_VERSION" ) ]
357
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
357
358
pub const fn first_chunk_mut < const N : usize > ( & mut self ) -> Option < & mut [ T ; N ] > {
358
359
if self . len ( ) < N {
359
360
None
@@ -384,6 +385,7 @@ impl<T> [T] {
384
385
#[ inline]
385
386
#[ stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
386
387
#[ rustc_const_stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
388
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
387
389
pub const fn split_first_chunk < const N : usize > ( & self ) -> Option < ( & [ T ; N ] , & [ T ] ) > {
388
390
if self . len ( ) < N {
389
391
None
@@ -418,7 +420,8 @@ impl<T> [T] {
418
420
/// ```
419
421
#[ inline]
420
422
#[ stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
421
- #[ rustc_const_unstable( feature = "const_slice_first_last_chunk" , issue = "111774" ) ]
423
+ #[ rustc_const_stable( feature = "const_slice_first_last_chunk" , since = "CURRENT_RUSTC_VERSION" ) ]
424
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
422
425
pub const fn split_first_chunk_mut < const N : usize > (
423
426
& mut self ,
424
427
) -> Option < ( & mut [ T ; N ] , & mut [ T ] ) > {
@@ -454,6 +457,7 @@ impl<T> [T] {
454
457
#[ inline]
455
458
#[ stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
456
459
#[ rustc_const_stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
460
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
457
461
pub const fn split_last_chunk < const N : usize > ( & self ) -> Option < ( & [ T ] , & [ T ; N ] ) > {
458
462
if self . len ( ) < N {
459
463
None
@@ -488,7 +492,8 @@ impl<T> [T] {
488
492
/// ```
489
493
#[ inline]
490
494
#[ stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
491
- #[ rustc_const_unstable( feature = "const_slice_first_last_chunk" , issue = "111774" ) ]
495
+ #[ rustc_const_stable( feature = "const_slice_first_last_chunk" , since = "CURRENT_RUSTC_VERSION" ) ]
496
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
492
497
pub const fn split_last_chunk_mut < const N : usize > (
493
498
& mut self ,
494
499
) -> Option < ( & mut [ T ] , & mut [ T ; N ] ) > {
@@ -524,6 +529,7 @@ impl<T> [T] {
524
529
#[ inline]
525
530
#[ stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
526
531
#[ rustc_const_stable( feature = "const_slice_last_chunk" , since = "1.80.0" ) ]
532
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
527
533
pub const fn last_chunk < const N : usize > ( & self ) -> Option < & [ T ; N ] > {
528
534
if self . len ( ) < N {
529
535
None
@@ -557,7 +563,8 @@ impl<T> [T] {
557
563
/// ```
558
564
#[ inline]
559
565
#[ stable( feature = "slice_first_last_chunk" , since = "1.77.0" ) ]
560
- #[ rustc_const_unstable( feature = "const_slice_first_last_chunk" , issue = "111774" ) ]
566
+ #[ rustc_const_stable( feature = "const_slice_first_last_chunk" , since = "CURRENT_RUSTC_VERSION" ) ]
567
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
561
568
pub const fn last_chunk_mut < const N : usize > ( & mut self ) -> Option < & mut [ T ; N ] > {
562
569
if self . len ( ) < N {
563
570
None
@@ -1900,7 +1907,8 @@ impl<T> [T] {
1900
1907
#[ inline]
1901
1908
#[ track_caller]
1902
1909
#[ must_use]
1903
- #[ rustc_const_unstable( feature = "const_slice_split_at_mut" , issue = "101804" ) ]
1910
+ #[ rustc_const_stable( feature = "const_slice_split_at_mut" , since = "CURRENT_RUSTC_VERSION" ) ]
1911
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
1904
1912
pub const fn split_at_mut ( & mut self , mid : usize ) -> ( & mut [ T ] , & mut [ T ] ) {
1905
1913
match self . split_at_mut_checked ( mid) {
1906
1914
Some ( pair) => pair,
@@ -2002,7 +2010,8 @@ impl<T> [T] {
2002
2010
/// assert_eq!(v, [1, 2, 3, 4, 5, 6]);
2003
2011
/// ```
2004
2012
#[ stable( feature = "slice_split_at_unchecked" , since = "1.79.0" ) ]
2005
- #[ rustc_const_unstable( feature = "const_slice_split_at_mut" , issue = "101804" ) ]
2013
+ #[ rustc_const_stable( feature = "const_slice_split_at_mut" , since = "CURRENT_RUSTC_VERSION" ) ]
2014
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
2006
2015
#[ inline]
2007
2016
#[ must_use]
2008
2017
pub const unsafe fn split_at_mut_unchecked ( & mut self , mid : usize ) -> ( & mut [ T ] , & mut [ T ] ) {
@@ -2102,7 +2111,8 @@ impl<T> [T] {
2102
2111
/// assert_eq!(None, v.split_at_mut_checked(7));
2103
2112
/// ```
2104
2113
#[ stable( feature = "split_at_checked" , since = "1.80.0" ) ]
2105
- #[ rustc_const_unstable( feature = "const_slice_split_at_mut" , issue = "101804" ) ]
2114
+ #[ rustc_const_stable( feature = "const_slice_split_at_mut" , since = "CURRENT_RUSTC_VERSION" ) ]
2115
+ #[ cfg_attr( bootstrap, rustc_allow_const_fn_unstable( const_mut_refs) ) ]
2106
2116
#[ inline]
2107
2117
#[ must_use]
2108
2118
pub const fn split_at_mut_checked ( & mut self , mid : usize ) -> Option < ( & mut [ T ] , & mut [ T ] ) > {
0 commit comments