about summary refs log tree commit diff
path: root/library/alloc/src
diff options
context:
space:
mode:
authorKevin Reid <kpreid@switchb.org>2023-09-24 08:55:19 -0700
committerKevin Reid <kpreid@switchb.org>2024-06-22 08:08:00 -0700
commitec201b8650e5026eadf14b20a5d2fd145d1975ba (patch)
treec4f610f854cda337657bbb722c6698a88b69a582 /library/alloc/src
parent433355166d769afc9c19f761cc7efc4d152e9a2c (diff)
downloadrust-ec201b8650e5026eadf14b20a5d2fd145d1975ba.tar.gz
rust-ec201b8650e5026eadf14b20a5d2fd145d1975ba.zip
Add `core::clone::CloneToUninit`.
This trait allows cloning DSTs, but is unsafe to implement and use
because it writes to possibly-uninitialized memory which must be of the
correct size, and must initialize that memory.

It is only implemented for `T: Clone` and `[T] where T: Clone`, but
additional implementations could be provided for specific `dyn Trait`
or custom-DST types.
Diffstat (limited to 'library/alloc/src')
0 files changed, 0 insertions, 0 deletions