iter_swap(ranges::transform_view::iterator)
From cppreference.com
< cpp | ranges | transform view | iterator
friend constexpr void iter_swap( const /*iterator*/& x, const /*iterator*/& y ) noexcept(/* see below */) |
(since C++20) | |
Swap the values of the elements the underlying iterators are pointing to.
Equivalent to ranges::iter_swap(x.current_, y.current_), where current_
denotes the underlying iterator.
This function is not visible to ordinary unqualified or qualified lookup, and can only be found by argument-dependent lookup when transform_view::iterator<Const>
is an associated class of the arguments.
Parameters
x, y | - | iterators to the elements to swap |
Return value
(none)
Exceptions
noexcept specification:
noexcept(noexcept(ranges::iter_swap(x.current_, y.current_)))
Notes
The effect is different from swap(*x, *y), which swaps the transformed elements.
Example
This section is incomplete Reason: no example |