pub struct InitClosure<F, T, E>(_, _);
Expand description

A closure initializer.

Implementations

Creates a new Init from the given closure

Safety

The closure

  • returns Ok(()) iff it initialized every field of place,
  • returns Err(err) iff it encountered an error and then cleaned place, this means:
    • place can be deallocated without UB ocurring,
    • place does not need to be dropped,
    • place is not partially initialized.
  • place may move after initialization

Trait Implementations

Initializes place. Read more
Initializes place. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.