cpp/utility/ranges/swap

Exchanges the values referenced by and.

is expression-equivalent to:
 * , if or  has class or enumeration type, and that expression is valid, where the overload resolution is performed within namespace  with the additional candidate.
 * 1) * If the function selected by overload resolution does not exchange the values referenced by and, the program is ill-formed; no diagnostic required.
 * 2) Otherwise,, if  and  are lvalue arrays of equal extent (but possibly different element types) and  is a valid expression, except that  is equal to.
 * 3) Otherwise, an expression which exchanges the referenced values of  and, if they are both lvalues of the same type  that models  and.
 * 4) * The result of applying the operator to that expression is equal to.
 * 5) * That expression is a constant expression if
 * 6) ** is a ,
 * 7) ** both and  are constant subexpressions, and
 * 8) ** the full-expressions of the initializers in the following declarations are constant subexpressions:
 * 9) Otherwise,  is ill-formed, which can result in substitution failure when  appears in the immediate context of a template instantiation.
 * 1) Otherwise,  is ill-formed, which can result in substitution failure when  appears in the immediate context of a template instantiation.
 * 1) Otherwise,  is ill-formed, which can result in substitution failure when  appears in the immediate context of a template instantiation.