Commit 740b052 1 parent 010c236 commit 740b052 Copy full SHA for 740b052
File tree 2 files changed +2
-3
lines changed
2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -23,14 +23,14 @@ mod iter;
23
23
pub use iter:: IntoIter ;
24
24
25
25
/// Converts a reference to `T` into a reference to an array of length 1 (without copying).
26
- #[ unstable ( feature = "array_from_ref" , issue = "77101 " ) ]
26
+ #[ stable ( feature = "array_from_ref" , since = "1.53.0 " ) ]
27
27
pub fn from_ref < T > ( s : & T ) -> & [ T ; 1 ] {
28
28
// SAFETY: Converting `&T` to `&[T; 1]` is sound.
29
29
unsafe { & * ( s as * const T ) . cast :: < [ T ; 1 ] > ( ) }
30
30
}
31
31
32
32
/// Converts a mutable reference to `T` into a mutable reference to an array of length 1 (without copying).
33
- #[ unstable ( feature = "array_from_ref" , issue = "77101 " ) ]
33
+ #[ stable ( feature = "array_from_ref" , since = "1.53.0 " ) ]
34
34
pub fn from_mut < T > ( s : & mut T ) -> & mut [ T ; 1 ] {
35
35
// SAFETY: Converting `&mut T` to `&mut [T; 1]` is sound.
36
36
unsafe { & mut * ( s as * mut T ) . cast :: < [ T ; 1 ] > ( ) }
Original file line number Diff line number Diff line change 1
1
#![ feature( alloc_layout_extra) ]
2
2
#![ feature( array_chunks) ]
3
- #![ feature( array_from_ref) ]
4
3
#![ feature( array_methods) ]
5
4
#![ feature( array_map) ]
6
5
#![ feature( array_windows) ]
You can’t perform that action at this time.
0 commit comments