library: Stabilize const_ptr_as_ref

Const-stabilizes:
- `NonNull::as_mut`
This commit is contained in:
Jubilee Young 2024-09-27 13:34:06 -07:00
parent bcc78bdc29
commit 966405d107
3 changed files with 2 additions and 3 deletions

View File

@ -140,7 +140,6 @@
#![feature(const_option_ext)]
#![feature(const_pin)]
#![feature(const_pointer_is_aligned)]
#![feature(const_ptr_as_ref)]
#![feature(const_ptr_is_null)]
#![feature(const_ptr_sub_ptr)]
#![feature(const_ptr_write)]

View File

@ -394,7 +394,8 @@ pub const fn as_ptr(self) -> *mut T {
///
/// [the module documentation]: crate::ptr#safety
#[stable(feature = "nonnull", since = "1.25.0")]
#[rustc_const_unstable(feature = "const_ptr_as_ref", issue = "91822")]
#[cfg_attr(bootstrap, rustc_allow_const_fn_unstable(const_mut_refs))]
#[rustc_const_stable(feature = "const_ptr_as_ref", since = "CURRENT_RUSTC_VERSION")]
#[must_use]
#[inline(always)]
pub const unsafe fn as_mut<'a>(&mut self) -> &'a mut T {

View File

@ -30,7 +30,6 @@
#![feature(const_option_ext)]
#![feature(const_pin)]
#![feature(const_pointer_is_aligned)]
#![feature(const_ptr_as_ref)]
#![feature(const_ptr_write)]
#![feature(const_result)]
#![feature(const_slice_from_ref)]