From 56735361536773aee70f44b76438d1a07b7062e3 Mon Sep 17 00:00:00 2001 From: Pointerbender <81013316+Pointerbender@users.noreply.github.com> Date: Mon, 24 Oct 2022 04:27:37 +0200 Subject: [PATCH] fix typos Co-authored-by: Ralf Jung --- library/core/src/cell.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library/core/src/cell.rs b/library/core/src/cell.rs index 12c6f211725..fe5dd7be8f6 100644 --- a/library/core/src/cell.rs +++ b/library/core/src/cell.rs @@ -1827,8 +1827,8 @@ impl fmt::Display for RefMut<'_, T> { /// order to avoid its interior mutability property from spreading from `T` into the `Outer` type, /// thus this can cause distortions in the type size in these cases. /// -/// Note that it is still only valid to obtain a `*mut T` pointer to the contents of a -/// _shared_ `UnsafeCell` through [`.get()`] or [`.raw_get()`]. A `&mut T` reference +/// Note that the only valid way to obtain a `*mut T` pointer to the contents of a +/// _shared_ `UnsafeCell` is through [`.get()`] or [`.raw_get()`]. A `&mut T` reference /// can be obtained by either dereferencing this pointer or by calling [`.get_mut()`] /// on an _exclusive_ `UnsafeCell`. Even though `T` and `UnsafeCell` have the /// same memory layout, the following is not allowed and undefined behavior: