23
General utilities library
[utilities]
23.5
Tuples
[tuple]
23.5.3
Class template
tuple
[tuple.tuple]
23.5.3.3
swap
[tuple.swap]
ðŸ”—
void swap(tuple& rhs) noexcept(
see below
);
1
#
Requires:
Each element in
*this
shall be swappable with (
[swappable.requirements]
) the corresponding element in
rhs
.
2
#
Effects:
Calls
swap
for each element in
*this
and its corresponding element in
rhs
.
3
#
Remarks:
The expression inside
noexcept
is equivalent to the logical
and
of the following expressions:
is_nothrow_swappable_v<
T
i
>
where
T
i
is the
i
th
type in
Types
.
4
#
Throws:
Nothing unless one of the element-wise
swap
calls throws an exception
.