Skip to main content

Clonable

Trait Clonable 

Source
pub trait Clonable: DynClone {
    // Required methods
    unsafe fn raw_clone_to(&self, dst: *mut u8);
    unsafe fn raw_move_to(&mut self, dst: *mut u8);
    unsafe fn raw_clone_from(&mut self, src: *const u8);
}

Required Methods§

Source

unsafe fn raw_clone_to(&self, dst: *mut u8)

Clone self into dst.

§Safety

dst must be a valid mutable reference to a value of type Self.

Source

unsafe fn raw_move_to(&mut self, dst: *mut u8)

Move the contents of self into dst, replacing the contents of self with Self::default().

§Safety

dst must be a valid mutable reference to a value of type Self.

Source

unsafe fn raw_clone_from(&mut self, src: *const u8)

Clone src into self.

§Safety

src must be a valid reference to a value of type Self.

Implementors§

Source§

impl<T: Clone + Default> Clonable for T