Skip to content

Commit d86516d

Browse files
committed
Stabilise weak_ptr_eq
1 parent 783469c commit d86516d

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

src/liballoc/rc.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -1843,7 +1843,6 @@ impl<T: ?Sized> Weak<T> {
18431843
/// # Examples
18441844
///
18451845
/// ```
1846-
/// #![feature(weak_ptr_eq)]
18471846
/// use std::rc::Rc;
18481847
///
18491848
/// let first_rc = Rc::new(5);
@@ -1861,7 +1860,6 @@ impl<T: ?Sized> Weak<T> {
18611860
/// Comparing `Weak::new`.
18621861
///
18631862
/// ```
1864-
/// #![feature(weak_ptr_eq)]
18651863
/// use std::rc::{Rc, Weak};
18661864
///
18671865
/// let first = Weak::new();
@@ -1873,7 +1871,7 @@ impl<T: ?Sized> Weak<T> {
18731871
/// assert!(!first.ptr_eq(&third));
18741872
/// ```
18751873
#[inline]
1876-
#[unstable(feature = "weak_ptr_eq", issue = "55981")]
1874+
#[stable(feature = "weak_ptr_eq", since = "1.39.0")]
18771875
pub fn ptr_eq(&self, other: &Self) -> bool {
18781876
self.ptr.as_ptr() == other.ptr.as_ptr()
18791877
}

src/liballoc/sync.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -1562,7 +1562,6 @@ impl<T: ?Sized> Weak<T> {
15621562
/// # Examples
15631563
///
15641564
/// ```
1565-
/// #![feature(weak_ptr_eq)]
15661565
/// use std::sync::Arc;
15671566
///
15681567
/// let first_rc = Arc::new(5);
@@ -1580,7 +1579,6 @@ impl<T: ?Sized> Weak<T> {
15801579
/// Comparing `Weak::new`.
15811580
///
15821581
/// ```
1583-
/// #![feature(weak_ptr_eq)]
15841582
/// use std::sync::{Arc, Weak};
15851583
///
15861584
/// let first = Weak::new();
@@ -1592,7 +1590,7 @@ impl<T: ?Sized> Weak<T> {
15921590
/// assert!(!first.ptr_eq(&third));
15931591
/// ```
15941592
#[inline]
1595-
#[unstable(feature = "weak_ptr_eq", issue = "55981")]
1593+
#[stable(feature = "weak_ptr_eq", since = "1.39.0")]
15961594
pub fn ptr_eq(&self, other: &Self) -> bool {
15971595
self.ptr.as_ptr() == other.ptr.as_ptr()
15981596
}

0 commit comments

Comments
 (0)