...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
Move constructor.
value( value&& other, storage_ptr sp);
The value is constructed with the contents of other
by move semantics, using the specified memory resource:
*other.storage() == *sp
,
ownership of the underlying memory is transferred in constant time,
with no possibility of exceptions. After construction, the moved-from
value becomes a null value with its current storage pointer.
*other.storage() != *sp
,
an element-wise copy is performed if other.is_structured() == true
, which may throw. In this case,
the moved-from value is not changed.
Constant or linear in the size of other
.
Strong guarantee. Calls to memory_resource::allocate
may throw.
Name |
Description |
---|---|
|
The value to move. |
|
A pointer to the |