Trait moveref::new::New

source ·
pub trait New: Sized {
    type Output;

    // Required method
    unsafe fn new(self, this: Pin<&mut MaybeUninit<Self::Output>>);
}
Expand description

Types which can be constructed (initialized) into some provided storage.

Required Associated Types§

Required Methods§

source

unsafe fn new(self, this: Pin<&mut MaybeUninit<Self::Output>>)

Initialize Self using this for storage.

§Safety
  • New::new() must not be used to mutate previously initialized data
  • this must be freshly-allocated memory
  • after invocation, the this placement argument is in a valid, initialized state

Object Safety§

This trait is not object safe.

Implementors§