-
Notifications
You must be signed in to change notification settings - Fork 13.8k
Added get_unchecked
and get_unchecked_mut
to OnceLock
and LazyLock
#138914
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Added get_unchecked
and get_unchecked_mut
to OnceLock
and LazyLock
#138914
Conversation
i dont know if the issue number can just point to a pull request? do i have to make a separate issue? |
This should go through an ACP first to gauge team interest. |
@HomelikeBrick42 Do you intend to open an ACP for this? |
i was going to but then i forgot about it, ill make one now |
i have made an ACP rust-lang/libs-team#654 |
With the ACP now accepted, we just need a tracking issue and the issue number updated in the PR. |
This adds methods for avoiding the atomic checks when accessing the value in a
OnceLock
orLazyLock