Closed
Description
These types are stable now, however, the docs don't properly mention them everywhere yet:
- https://doc.rust-lang.org/nightly/std/cell/index.html lists OnceCell in the overview, but not LazyCell. The docs should also explain when I should use which of these types, as they are superficially pretty similar.
- https://doc.rust-lang.org/nightly/std/sync/index.html#higher-level-synchronization-objects lists Once and OnceLock, but not LazyLock. The same point about "when to use which type" applies. (It seems like
Once
is basically the same asOnceLock<()>
, but I am not sure.)
Cc @rust-lang/libs-api
Metadata
Metadata
Assignees
Labels
Area: Documentation for any part of the project, including the compiler, standard library, and toolsCategory: An issue proposing an enhancement or a PR with one.Relevant to the library team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.