Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the master branch, built from commit 064f557086.
PrevUpHomeNext
string::string (10 of 12 overloads)

Move constructor.

Synopsis
string(
    string&& other);
Description

Constructs the string with the contents of other using move semantics. Ownership of the underlying memory is transferred. The container acquires shared ownership of the boost::container::pmr::memory_resource used by other. After construction, the moved-from string behaves as if newly constructed with its current memory resource.

Complexity

Constant.

Parameters

Name

Description

other

The string to move


PrevUpHomeNext