Moving, Forwarding, Swapping<utility>
This section explains move(), move_if_noexcept(), forward(), swap(), and exchange(). In passing, it also introduces the concepts of move semantics and perfect forwarding.
An object can be moved elsewhere (rather than copied) if its previous user no longer needs it. Moving the resources from one object to another can often be implemented far more efficiently than (deep) copying them. For a string object, for instance, moving is typically as simple as copying a char* pointer ...