Šimon Tóth’s Post

View profile for Šimon Tóth

C++ Educational Content Creator | 20 years of Software Engineering experience distilled into digestible daily posts

The std::iter_swap is a convenient shorthand for indirectly swapping values, i.e. swapping the values pointed to by two iterators. While the original version std::iter_swap is only intended for iterators, the range C++20 version std::ranges::iter_swap can work with any indirectly movable type and supports customization through ADL. Compiler Explorer link: https://lnkd.in/eNJxW6RB #cpp #cplusplus #coding #programming #dailybiteofcpp

  • text
SEBASTIEN LEVY

m374-crypt0880 followers

1y

Thanks for this daily example ! I'm curious, at en.cppreference.com, the sentinel_for concept has 2 template parameters, am I missing something ?

Like
Reply

To view or add a comment, sign in

Explore content categories