-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Add RefCell<T>::replace_with #45819
Add RefCell<T>::replace_with #45819
Conversation
(cc @rust-lang/libs) |
r? @BurntSushi Just to get some reviewer on this. |
Ping from triage, @BurntSushi — will you be able to spend some time on this? |
@bors: r+ Thanks! |
📌 Commit 2d02772 has been approved by |
Add RefCell<T>::replace_with I also moved the `Panic` sections to before examples in the other two functions also under this feature gate, and changed the variable names in `replace` to be more readable. r? @rust-libs
☀️ Test successful - status-appveyor, status-travis |
In which sense does |
In the same sense that RefCell::replace corresponds to mem::replace. Though with the |
Well, |
I also moved the
Panic
sections to before examples in the other two functions also under this feature gate, and changed the variable names inreplace
to be more readable.r? @rust-libs