Swap the values of the specified a and b pairs.
Synopsis
Declared in <bslstl_pair.h>
template<
class T1,
class T2>
void
swap(
pair<T1, T2>& a,
pair<T1, T2>& b) noexcept(noexcept(a.swap(b)))
requires bsl::is_swappable<T1>::value && bsl::is_swappable<T2>::value;
Description
Swap the values of the specified a and b pairs by applying swap to each of the first and second pair fields. Note that this method is no‐throw only if swap on each field is no‐throw.
Parameters
Name |
Description |
a |
first pair to exchange |
b |
second pair to exchange |
Created with MrDocs