Skip to content

Commit

Permalink
Rollup merge of #103580 - lukas-code:guaranteed_ne, r=GuillaumeGomez
Browse files Browse the repository at this point in the history
Fix typo in docs for `guaranteed_ne`

`==` -> `!=`
  • Loading branch information
Yuki Okushi committed Oct 26, 2022
2 parents 1d5f328 + cce46e9 commit 77145c0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion library/core/src/ptr/const_ptr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -802,7 +802,7 @@ impl<T: ?Sized> *const T {

/// Returns whether two pointers are guaranteed to be inequal.
///
/// At runtime this function behaves like `Some(self == other)`.
/// At runtime this function behaves like `Some(self != other)`.
/// However, in some contexts (e.g., compile-time evaluation),
/// it is not always possible to determine inequality of two pointers, so this function may
/// spuriously return `None` for pointers that later actually turn out to have its inequality known.
Expand Down
2 changes: 1 addition & 1 deletion library/core/src/ptr/mut_ptr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -730,7 +730,7 @@ impl<T: ?Sized> *mut T {

/// Returns whether two pointers are guaranteed to be inequal.
///
/// At runtime this function behaves like `Some(self == other)`.
/// At runtime this function behaves like `Some(self != other)`.
/// However, in some contexts (e.g., compile-time evaluation),
/// it is not always possible to determine inequality of two pointers, so this function may
/// spuriously return `None` for pointers that later actually turn out to have its inequality known.
Expand Down

0 comments on commit 77145c0

Please sign in to comment.