Module moveit::ctor[][src]

In-place constructors.

Traits

Assign

Extension trait for adding assign() to Pin<&mut T>.

CopyCtor

A copy constructible type: a destination-aware Clone.

Ctor

An in-place constructor for a particular type.

Emplace

A pointer type with a stable address that a Ctor may be used to construct a value with.

MoveCtor

A move constructible type: a destination-aware Clone that destroys the moved-from value.

TryCtor

An in-place constructor for a particular type, which can potentially fail.

Functions

assign

Assigns a new value into lvalue, destroying the previous occupant.

copy

Returns a new Ctor that uses a copy constructor.

default

Returns a new Ctor that uses a Default implementation to generate a T.

from

Returns a new Ctor that uses a From implementation to generate a T.

from_fn

Returns a new Ctor that uses the provided closure for constructing a T.

from_placement_fn

Returns a new Ctor that uses the provided closure for construction.

from_placement_try_fn

Returns a new TryCtor that uses the provided closure for construction.

from_try_fn

Returns a new Ctor that uses the provided closure for constructing a T.

mov

Returns a new Ctor that uses a move constructor.

new

Returns a new Ctor that simply returns the given value.

try_assign

Assigns a new value into lvalue, destroying the previous occupant.

try_from

Returns a new Ctor that uses a From implementation to generate a T.