bump bootstrap; adjust stage0 uses in core::ptr.
This commit is contained in:
parent
750983d356
commit
0b46f0e649
@ -2913,7 +2913,7 @@ impl<T: Sized> NonNull<T> {
|
||||
/// some other means.
|
||||
#[stable(feature = "nonnull", since = "1.25.0")]
|
||||
#[inline]
|
||||
#[cfg_attr(not(stage0), rustc_const_unstable(feature = "const_ptr_nonnull"))]
|
||||
#[rustc_const_unstable(feature = "const_ptr_nonnull")]
|
||||
pub const fn dangling() -> Self {
|
||||
unsafe {
|
||||
let ptr = mem::align_of::<T>() as *mut T;
|
||||
@ -2977,7 +2977,7 @@ impl<T: ?Sized> NonNull<T> {
|
||||
/// Cast to a pointer of another type
|
||||
#[stable(feature = "nonnull_cast", since = "1.27.0")]
|
||||
#[inline]
|
||||
#[cfg_attr(not(stage0), rustc_const_unstable(feature = "const_ptr_nonnull"))]
|
||||
#[rustc_const_unstable(feature = "const_ptr_nonnull")]
|
||||
pub const fn cast<U>(self) -> NonNull<U> {
|
||||
unsafe {
|
||||
NonNull::new_unchecked(self.as_ptr() as *mut U)
|
||||
|
Loading…
Reference in New Issue
Block a user