Namespaces
Variants
Actions

std::ranges::views::common, std::ranges::common_view

From cppreference.com
< cpp‎ | ranges
 
 
Ranges library
Range adaptors
 
 
Defined in header <ranges>
template< ranges::view V >

    requires (not ranges::common_range<V> and
              std::copyable<ranges::iterator_t<V>>)
class common_view

    : public ranges::view_interface<common_view<V>>
(1) (since C++20)
namespace views {

    inline constexpr /* unspecified */ common = /* unspecified */;

}
(2) (since C++20)
Call signature
template< ranges::viewable_range R >

    requires /* see below */

constexpr ranges::view auto common( R&& r );
(since C++20)
1) Adapts a given view with different types for iterator/sentinel pair into a view that is also a common_range. A common_view always has the same iterator/sentinel type.
2)