libycxx

function object

std::ranges::views::single

Header
<ranges>
Scope
std::ranges::views
cppreference
<ranges> nearest page

Synopsis

inline constexpr /* implementation-defined */ single = {};

Call signatures

single is a function object; these are its call operators as libycxx declares them, written as the functions the draft declares.

  1. template<class T>
      requires requires { std::ranges::single_view<std::decay_t<T>>(std::declval<T>()); }
    [[nodiscard]] constexpr auto single(
        T&& t) noexcept(noexcept(std::ranges::single_view<std::decay_t<T>>(static_cast<T &&>(t))));
    (1)