diff --git a/src/liballoc/rc.rs b/src/liballoc/rc.rs index 4d50ae9efca95..f864852ec6324 100644 --- a/src/liballoc/rc.rs +++ b/src/liballoc/rc.rs @@ -1706,7 +1706,7 @@ impl Weak { /// ``` /// /// [`null`]: ../../std/ptr/fn.null.html - #[stable(feature = "weak_into_raw", since = "1.45.0")] + #[stable(feature = "rc_as_ptr", since = "1.45.0")] pub fn as_ptr(&self) -> *const T { let offset = data_offset_sized::(); let ptr = self.ptr.cast::().as_ptr().wrapping_offset(offset); diff --git a/src/liballoc/sync.rs b/src/liballoc/sync.rs index 826f0c8fa833f..0bead76a501c8 100644 --- a/src/liballoc/sync.rs +++ b/src/liballoc/sync.rs @@ -587,7 +587,7 @@ impl Arc { /// assert_eq!(x_ptr, Arc::as_ptr(&y)); /// assert_eq!(unsafe { &*x_ptr }, "hello"); /// ``` - #[stable(feature = "weak_into_raw", since = "1.45.0")] + #[stable(feature = "rc_as_ptr", since = "1.45.0")] pub fn as_ptr(this: &Self) -> *const T { let ptr: *mut ArcInner = NonNull::as_ptr(this.ptr); let fake_ptr = ptr as *mut T;