@@ -5,7 +5,7 @@ use crate::ops;
55use crate :: ptr;
66
77#[ stable( feature = "rust1" , since = "1.0.0" ) ]
8- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
8+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
99impl < T , I > const ops:: Index < I > for [ T ]
1010where
1111 I : ~const SliceIndex < [ T ] > ,
1919}
2020
2121#[ stable( feature = "rust1" , since = "1.0.0" ) ]
22- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
22+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
2323impl < T , I > const ops:: IndexMut < I > for [ T ]
2424where
2525 I : ~const SliceIndex < [ T ] > ,
@@ -30,16 +30,19 @@ where
3030 }
3131}
3232
33-
3433#[ cfg_attr( not( feature = "panic_immediate_abort" ) , inline( never) ) ]
3534#[ cfg_attr( feature = "panic_immediate_abort" , inline) ]
3635#[ cold]
3736#[ track_caller]
38- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
37+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
3938const fn slice_start_index_len_fail ( index : usize , len : usize ) -> ! {
4039 // SAFETY: we are just panicking here
4140 unsafe {
42- const_eval_select ( ( index, len) , slice_start_index_len_fail_ct, slice_start_index_len_fail_rt)
41+ const_eval_select (
42+ ( index, len) ,
43+ slice_start_index_len_fail_ct,
44+ slice_start_index_len_fail_rt,
45+ )
4346 }
4447}
4548
@@ -56,7 +59,7 @@ const fn slice_start_index_len_fail_ct(_: usize, _: usize) -> ! {
5659#[ cfg_attr( feature = "panic_immediate_abort" , inline) ]
5760#[ cold]
5861#[ track_caller]
59- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
62+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
6063const fn slice_end_index_len_fail ( index : usize , len : usize ) -> ! {
6164 // SAFETY: we are just panicking here
6265 unsafe {
@@ -77,7 +80,7 @@ const fn slice_end_index_len_fail_ct(_: usize, _: usize) -> ! {
7780#[ cfg_attr( feature = "panic_immediate_abort" , inline) ]
7881#[ cold]
7982#[ track_caller]
80- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
83+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
8184const fn slice_index_order_fail ( index : usize , end : usize ) -> ! {
8285 // SAFETY: we are just panicking here
8386 unsafe { const_eval_select ( ( index, end) , slice_index_order_fail_ct, slice_index_order_fail_rt) }
@@ -194,7 +197,7 @@ pub unsafe trait SliceIndex<T: ?Sized>: private_slice_index::Sealed {
194197}
195198
196199#[ stable( feature = "slice_get_slice_impls" , since = "1.15.0" ) ]
197- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
200+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
198201unsafe impl < T > const SliceIndex < [ T ] > for usize {
199202 type Output = T ;
200203
@@ -239,7 +242,7 @@ unsafe impl<T> const SliceIndex<[T]> for usize {
239242}
240243
241244#[ stable( feature = "slice_get_slice_impls" , since = "1.15.0" ) ]
242- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
245+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
243246unsafe impl < T > const SliceIndex < [ T ] > for ops:: Range < usize > {
244247 type Output = [ T ] ;
245248
@@ -304,7 +307,7 @@ unsafe impl<T> const SliceIndex<[T]> for ops::Range<usize> {
304307}
305308
306309#[ stable( feature = "slice_get_slice_impls" , since = "1.15.0" ) ]
307- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
310+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
308311unsafe impl < T > const SliceIndex < [ T ] > for ops:: RangeTo < usize > {
309312 type Output = [ T ] ;
310313
@@ -342,7 +345,7 @@ unsafe impl<T> const SliceIndex<[T]> for ops::RangeTo<usize> {
342345}
343346
344347#[ stable( feature = "slice_get_slice_impls" , since = "1.15.0" ) ]
345- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
348+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
346349unsafe impl < T > const SliceIndex < [ T ] > for ops:: RangeFrom < usize > {
347350 type Output = [ T ] ;
348351
@@ -388,7 +391,7 @@ unsafe impl<T> const SliceIndex<[T]> for ops::RangeFrom<usize> {
388391}
389392
390393#[ stable( feature = "slice_get_slice_impls" , since = "1.15.0" ) ]
391- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
394+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
392395unsafe impl < T > const SliceIndex < [ T ] > for ops:: RangeFull {
393396 type Output = [ T ] ;
394397
@@ -424,7 +427,7 @@ unsafe impl<T> const SliceIndex<[T]> for ops::RangeFull {
424427}
425428
426429#[ stable( feature = "inclusive_range" , since = "1.26.0" ) ]
427- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
430+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
428431unsafe impl < T > const SliceIndex < [ T ] > for ops:: RangeInclusive < usize > {
429432 type Output = [ T ] ;
430433
@@ -468,7 +471,7 @@ unsafe impl<T> const SliceIndex<[T]> for ops::RangeInclusive<usize> {
468471}
469472
470473#[ stable( feature = "inclusive_range" , since = "1.26.0" ) ]
471- #[ rustc_const_unstable( feature = "const_slice_index_impls " , issue = "none" ) ]
474+ #[ rustc_const_unstable( feature = "const_slice_index " , issue = "none" ) ]
472475unsafe impl < T > const SliceIndex < [ T ] > for ops:: RangeToInclusive < usize > {
473476 type Output = [ T ] ;
474477
0 commit comments