Unnamed repository; edit this file 'description' to name the repository.
Auto merge of #149079 - zachs18:clone_from_ref, r=Mark-Simulacrum
Add `Box::clone_from_ref` and similar under `feature(clone_from_ref)` Tracking issue: https://github.com/rust-lang/rust/issues/149075 Accepted ACP: https://github.com/rust-lang/libs-team/issues/483 This PR implements `clone_from_ref` (and `try_*` and `_*in` variants), to get a `Box<T>`, `Arc<T>`, or `Rc<T>` by cloning from a `&T` where `T: CloneToUninit`. The "Implement..." commits replace some ad-hoc conversions with `clone_from_ref` variants, which can be split out to a separate PR if desired. This PR will conflict with https://github.com/rust-lang/rust/pull/148769 due to usage of `Layout::dangling` (which that PR is renaming to `dangling_ptr`), so they should not be rolled up together, and the one which merges later will need to be amended.
bors 5 months ago
parent de1d8aa · parent 4592602 · commit 53d2132
0 files changed, 0 insertions, 0 deletions