Skip to main content

UnsizedCopy

Trait UnsizedCopy 

Source
pub unsafe trait UnsizedCopy { }
Expand description

Unsafe marker trait for types that can be copied, including unsized types such as slices.

§Safety

The implementor must ensure Self has a memory representation which can be duplicated without violating soundness or causing double frees.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl UnsizedCopy for CStr

Source§

impl UnsizedCopy for str

Source§

impl<T: Copy> UnsizedCopy for [T]

Implementors§

Source§

impl<T: Copy> UnsizedCopy for T