Skip to content

Commit dbbbed0

Browse files
authored
Rollup merge of #135556 - AeonSolstice:patch-1, r=tgross35
Clarify note in `std::sync::LazyLock` example I doubt most people know what it means, as I did not until a week ago. In the current form, it seems like a `TODO:`.
2 parents 10d22fc + c4a5e12 commit dbbbed0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/std/src/sync/lazy_lock.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ union Data<T, F> {
3131
/// ```
3232
/// use std::sync::LazyLock;
3333
///
34-
/// // n.b. static items do not call [`Drop`] on program termination, so this won't be deallocated.
34+
/// // Note: static items do not call [`Drop`] on program termination, so this won't be deallocated.
3535
/// // this is fine, as the OS can deallocate the terminated program faster than we can free memory
3636
/// // but tools like valgrind might report "memory leaks" as it isn't obvious this is intentional.
3737
/// static DEEP_THOUGHT: LazyLock<String> = LazyLock::new(|| {

0 commit comments

Comments
 (0)