mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-05 19:58:32 +00:00
Update {rc, sync}::Weak::ptr_eq doc about comparing Weak::new
This commit is contained in:
parent
d86516d91e
commit
307804a00d
@ -1832,8 +1832,9 @@ impl<T: ?Sized> Weak<T> {
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns `true` if the two `Weak`s point to the same value (not just values
|
||||
/// that compare as equal).
|
||||
/// Returns `true` if the two `Weak`s point to the same value (not just
|
||||
/// values that compare as equal), or if both don't point to any value
|
||||
/// (because they were created with `Weak::new()`).
|
||||
///
|
||||
/// # Notes
|
||||
///
|
||||
|
@ -1550,15 +1550,15 @@ impl<T: ?Sized> Weak<T> {
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns `true` if the two `Weak`s point to the same value (not just values
|
||||
/// that compare as equal).
|
||||
/// Returns `true` if the two `Weak`s point to the same value (not just
|
||||
/// values that compare as equal), or if both don't point to any value
|
||||
/// (because they were created with `Weak::new()`).
|
||||
///
|
||||
/// # Notes
|
||||
///
|
||||
/// Since this compares pointers it means that `Weak::new()` will equal each
|
||||
/// other, even though they don't point to any value.
|
||||
///
|
||||
///
|
||||
/// # Examples
|
||||
///
|
||||
/// ```
|
||||
|
Loading…
Reference in New Issue
Block a user