@@ -559,8 +559,6 @@ impl<T, const N: usize> [T; N] {
559559 /// # Example
560560 ///
561561 /// ```
562- /// #![feature(array_methods)]
563- ///
564562 /// let floats = [3.1, 2.7, -1.0];
565563 /// let float_refs: [&f64; 3] = floats.each_ref();
566564 /// assert_eq!(float_refs, [&3.1, &2.7, &-1.0]);
@@ -571,16 +569,14 @@ impl<T, const N: usize> [T; N] {
571569 /// array if its elements are not [`Copy`].
572570 ///
573571 /// ```
574- /// #![feature(array_methods)]
575- ///
576572 /// let strings = ["Ferris".to_string(), "♥".to_string(), "Rust".to_string()];
577573 /// let is_ascii = strings.each_ref().map(|s| s.is_ascii());
578574 /// assert_eq!(is_ascii, [true, false, true]);
579575 ///
580576 /// // We can still access the original array: it has not been moved.
581577 /// assert_eq!(strings.len(), 3);
582578 /// ```
583- #[ unstable ( feature = "array_methods" , issue = "76118 " ) ]
579+ #[ stable ( feature = "array_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
584580 pub fn each_ref ( & self ) -> [ & T ; N ] {
585581 from_trusted_iterator ( self . iter ( ) )
586582 }
@@ -592,15 +588,14 @@ impl<T, const N: usize> [T; N] {
592588 /// # Example
593589 ///
594590 /// ```
595- /// #![feature(array_methods)]
596591 ///
597592 /// let mut floats = [3.1, 2.7, -1.0];
598593 /// let float_refs: [&mut f64; 3] = floats.each_mut();
599594 /// *float_refs[0] = 0.0;
600595 /// assert_eq!(float_refs, [&mut 0.0, &mut 2.7, &mut -1.0]);
601596 /// assert_eq!(floats, [0.0, 2.7, -1.0]);
602597 /// ```
603- #[ unstable ( feature = "array_methods" , issue = "76118 " ) ]
598+ #[ stable ( feature = "array_methods" , since = "CURRENT_RUSTC_VERSION " ) ]
604599 pub fn each_mut ( & mut self ) -> [ & mut T ; N ] {
605600 from_trusted_iterator ( self . iter_mut ( ) )
606601 }
0 commit comments