diff options
| author | Maybe Waffle <waffle.lapkin@gmail.com> | 2021-10-23 20:59:15 +0300 |
|---|---|---|
| committer | Maybe Waffle <waffle.lapkin@gmail.com> | 2021-10-23 20:59:15 +0300 |
| commit | 27d69611347142cc5f103df0923b46d670e75739 (patch) | |
| tree | a7bf636fe4510afa3f196d188e65797a7846bddc /library/core/src/array | |
| parent | a288bf6afbf7f98fd357b971b23ef09a66aaa8c0 (diff) | |
| download | rust-27d69611347142cc5f103df0923b46d670e75739.tar.gz rust-27d69611347142cc5f103df0923b46d670e75739.zip | |
Fill tracking issue for `const_slice_from_ref` and `const_array_from_ref`
Diffstat (limited to 'library/core/src/array')
| -rw-r--r-- | library/core/src/array/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs index 752e3fceb35..5286ea60e3f 100644 --- a/library/core/src/array/mod.rs +++ b/library/core/src/array/mod.rs @@ -85,7 +85,7 @@ where /// Converts a reference to `T` into a reference to an array of length 1 (without copying). #[stable(feature = "array_from_ref", since = "1.53.0")] -#[rustc_const_unstable(feature = "const_array_from_ref", issue = "none")] +#[rustc_const_unstable(feature = "const_array_from_ref", issue = "90206")] pub const fn from_ref<T>(s: &T) -> &[T; 1] { // SAFETY: Converting `&T` to `&[T; 1]` is sound. unsafe { &*(s as *const T).cast::<[T; 1]>() } @@ -93,7 +93,7 @@ pub const fn from_ref<T>(s: &T) -> &[T; 1] { /// Converts a mutable reference to `T` into a mutable reference to an array of length 1 (without copying). #[stable(feature = "array_from_ref", since = "1.53.0")] -#[rustc_const_unstable(feature = "const_array_from_ref", issue = "none")] +#[rustc_const_unstable(feature = "const_array_from_ref", issue = "90206")] pub const fn from_mut<T>(s: &mut T) -> &mut [T; 1] { // SAFETY: Converting `&mut T` to `&mut [T; 1]` is sound. unsafe { &mut *(s as *mut T).cast::<[T; 1]>() } |
