@@ -713,8 +713,6 @@ impl<T> [T] {
713713 /// # Examples
714714 ///
715715 /// ```
716- /// #![feature(chunks_exact)]
717- ///
718716 /// let slice = ['l', 'o', 'r', 'e', 'm'];
719717 /// let mut iter = slice.chunks_exact(2);
720718 /// assert_eq!(iter.next().unwrap(), &['l', 'o']);
@@ -725,7 +723,7 @@ impl<T> [T] {
725723 ///
726724 /// [`chunks`]: #method.chunks
727725 /// [`rchunks_exact`]: #method.rchunks_exact
728- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
726+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
729727 #[ inline]
730728 pub fn chunks_exact ( & self , chunk_size : usize ) -> ChunksExact < T > {
731729 assert ! ( chunk_size != 0 ) ;
@@ -756,8 +754,6 @@ impl<T> [T] {
756754 /// # Examples
757755 ///
758756 /// ```
759- /// #![feature(chunks_exact)]
760- ///
761757 /// let v = &mut [0, 0, 0, 0, 0];
762758 /// let mut count = 1;
763759 ///
@@ -772,7 +768,7 @@ impl<T> [T] {
772768 ///
773769 /// [`chunks_mut`]: #method.chunks_mut
774770 /// [`rchunks_exact_mut`]: #method.rchunks_exact_mut
775- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
771+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
776772 #[ inline]
777773 pub fn chunks_exact_mut ( & mut self , chunk_size : usize ) -> ChunksExactMut < T > {
778774 assert ! ( chunk_size != 0 ) ;
@@ -4022,25 +4018,25 @@ unsafe impl<'a, T> TrustedRandomAccess for ChunksMut<'a, T> {
40224018/// [`remainder`]: ../../std/slice/struct.ChunksExact.html#method.remainder
40234019/// [slices]: ../../std/primitive.slice.html
40244020#[ derive( Debug ) ]
4025- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4021+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
40264022pub struct ChunksExact < ' a , T : ' a > {
40274023 v : & ' a [ T ] ,
40284024 rem : & ' a [ T ] ,
40294025 chunk_size : usize
40304026}
40314027
4032- #[ unstable( feature = "chunks_exact" , issue = "47115" ) ]
40334028impl < ' a , T > ChunksExact < ' a , T > {
40344029 /// Return the remainder of the original slice that is not going to be
40354030 /// returned by the iterator. The returned slice has at most `chunk_size-1`
40364031 /// elements.
4032+ #[ stable( feature = "chunks_exact" , since = "1.31.0" ) ]
40374033 pub fn remainder ( & self ) -> & ' a [ T ] {
40384034 self . rem
40394035 }
40404036}
40414037
40424038// FIXME(#26925) Remove in favor of `#[derive(Clone)]`
4043- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4039+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
40444040impl < T > Clone for ChunksExact < ' _ , T > {
40454041 fn clone ( & self ) -> Self {
40464042 ChunksExact {
@@ -4051,7 +4047,7 @@ impl<T> Clone for ChunksExact<'_, T> {
40514047 }
40524048}
40534049
4054- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4050+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
40554051impl < ' a , T > Iterator for ChunksExact < ' a , T > {
40564052 type Item = & ' a [ T ] ;
40574053
@@ -4096,7 +4092,7 @@ impl<'a, T> Iterator for ChunksExact<'a, T> {
40964092 }
40974093}
40984094
4099- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4095+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
41004096impl < ' a , T > DoubleEndedIterator for ChunksExact < ' a , T > {
41014097 #[ inline]
41024098 fn next_back ( & mut self ) -> Option < & ' a [ T ] > {
@@ -4110,7 +4106,7 @@ impl<'a, T> DoubleEndedIterator for ChunksExact<'a, T> {
41104106 }
41114107}
41124108
4113- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4109+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
41144110impl < T > ExactSizeIterator for ChunksExact < ' _ , T > {
41154111 fn is_empty ( & self ) -> bool {
41164112 self . v . is_empty ( )
@@ -4120,11 +4116,11 @@ impl<T> ExactSizeIterator for ChunksExact<'_, T> {
41204116#[ unstable( feature = "trusted_len" , issue = "37572" ) ]
41214117unsafe impl < T > TrustedLen for ChunksExact < ' _ , T > { }
41224118
4123- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4119+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
41244120impl < T > FusedIterator for ChunksExact < ' _ , T > { }
41254121
41264122#[ doc( hidden) ]
4127- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4123+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
41284124unsafe impl < ' a , T > TrustedRandomAccess for ChunksExact < ' a , T > {
41294125 unsafe fn get_unchecked ( & mut self , i : usize ) -> & ' a [ T ] {
41304126 let start = i * self . chunk_size ;
@@ -4146,24 +4142,24 @@ unsafe impl<'a, T> TrustedRandomAccess for ChunksExact<'a, T> {
41464142/// [`into_remainder`]: ../../std/slice/struct.ChunksExactMut.html#method.into_remainder
41474143/// [slices]: ../../std/primitive.slice.html
41484144#[ derive( Debug ) ]
4149- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4145+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
41504146pub struct ChunksExactMut < ' a , T : ' a > {
41514147 v : & ' a mut [ T ] ,
41524148 rem : & ' a mut [ T ] ,
41534149 chunk_size : usize
41544150}
41554151
4156- #[ unstable( feature = "chunks_exact" , issue = "47115" ) ]
41574152impl < ' a , T > ChunksExactMut < ' a , T > {
41584153 /// Return the remainder of the original slice that is not going to be
41594154 /// returned by the iterator. The returned slice has at most `chunk_size-1`
41604155 /// elements.
4156+ #[ stable( feature = "chunks_exact" , since = "1.31.0" ) ]
41614157 pub fn into_remainder ( self ) -> & ' a mut [ T ] {
41624158 self . rem
41634159 }
41644160}
41654161
4166- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4162+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
41674163impl < ' a , T > Iterator for ChunksExactMut < ' a , T > {
41684164 type Item = & ' a mut [ T ] ;
41694165
@@ -4210,7 +4206,7 @@ impl<'a, T> Iterator for ChunksExactMut<'a, T> {
42104206 }
42114207}
42124208
4213- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4209+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
42144210impl < ' a , T > DoubleEndedIterator for ChunksExactMut < ' a , T > {
42154211 #[ inline]
42164212 fn next_back ( & mut self ) -> Option < & ' a mut [ T ] > {
@@ -4226,7 +4222,7 @@ impl<'a, T> DoubleEndedIterator for ChunksExactMut<'a, T> {
42264222 }
42274223}
42284224
4229- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4225+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
42304226impl < T > ExactSizeIterator for ChunksExactMut < ' _ , T > {
42314227 fn is_empty ( & self ) -> bool {
42324228 self . v . is_empty ( )
@@ -4236,11 +4232,11 @@ impl<T> ExactSizeIterator for ChunksExactMut<'_, T> {
42364232#[ unstable( feature = "trusted_len" , issue = "37572" ) ]
42374233unsafe impl < T > TrustedLen for ChunksExactMut < ' _ , T > { }
42384234
4239- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4235+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
42404236impl < T > FusedIterator for ChunksExactMut < ' _ , T > { }
42414237
42424238#[ doc( hidden) ]
4243- #[ unstable ( feature = "chunks_exact" , issue = "47115 " ) ]
4239+ #[ stable ( feature = "chunks_exact" , since = "1.31.0 " ) ]
42444240unsafe impl < ' a , T > TrustedRandomAccess for ChunksExactMut < ' a , T > {
42454241 unsafe fn get_unchecked ( & mut self , i : usize ) -> & ' a mut [ T ] {
42464242 let start = i * self . chunk_size ;
0 commit comments