@@ -2,12 +2,12 @@ use crate::cell::UnsafeCell; |
|
|
2 |
2 |
use crate::fmt; |
3 |
3 |
use crate::mem; |
4 |
4 |
|
5 |
|
-/// A cell which can be written to only once. |
|
5 |
+/// A cell which can nominally be written to only once. |
6 |
6 |
/// |
7 |
7 |
/// This allows obtaining a shared `&T` reference to its inner value without copying or replacing |
8 |
8 |
/// it (unlike [`Cell`]), and without runtime borrow checks (unlike [`RefCell`]). However, |
9 |
9 |
/// only immutable references can be obtained unless one has a mutable reference to the cell |
10 |
|
-/// itself. |
|
10 |
+/// itself. In the same vein, the cell can only be re-initialized with such a mutable reference. |
11 |
11 |
/// |
12 |
12 |
/// For a thread-safe version of this struct, see [`std::sync::OnceLock`]. |
13 |
13 |
/// |