![]() |
Home | Libraries | People | FAQ | More |
Assignment.
value& operator=(array&& arr);
The contents of the value are replaced with the contents of arr using move semantics:
*arr.storage() == *this->storage(), ownership of the underlying memory
is transferred in constant time, with no possibility of exceptions.
After assignment, the moved-from array becomes empty with its current
storage pointer.
*arr.storage() != *this->storage(), an element-wise copy is performed,
which may throw. In this case, the moved-from array is not changed.
Constant, or linear in the size of *this plus arr.size().
Strong guarantee. Calls to memory_resource::allocate
may throw.
|
Name |
Description |
|---|---|
|
|
The array to move-assign from. |