5 #ifndef VCCC_RANGES_RANGE_ADAPTOR_HPP_
6 #define VCCC_RANGES_RANGE_ADAPTOR_HPP_
24 template<
typename Niebloid,
typename... Args>
30 template<
typename... T, std::enable_if_t<
conjunction<
36 : args_(
std::forward<T>(args)...) {}
39 constexpr decltype(
auto) operator()(R&& r) & {
40 return call(*
this, std::forward<R>(r), std::index_sequence_for<Args...>{});
43 template<
typename R, std::enable_if_t<
is_invocable<Niebloid, R,
const Args&...>
::value,
int> = 0>
44 constexpr decltype(
auto) operator()(R&& r) const & {
45 return call(*
this, std::forward<R>(r), std::index_sequence_for<Args...>{});
48 template<
typename R, std::enable_if_t<
is_invocable<Niebloid, R, Args&&...>
::value,
int> = 0>
49 constexpr decltype(
auto) operator()(R&& r) && {
50 return call(std::move(*
this), std::forward<R>(r), std::index_sequence_for<Args...>{});
53 template<
typename R, std::enable_if_t<
is_invocable<Niebloid, R,
const Args&&...>
::value,
int> = 0>
54 constexpr decltype(
auto) operator()(R&& r) const && {
55 return call(std::move(*
this), std::forward<R>(r), std::index_sequence_for<Args...>{});
59 template<
typename This,
typename R, std::size_t... I>
60 static constexpr decltype(
auto) call(This&& thiz, R&& r,
std::index_sequence<I...>) {
61 return Niebloid{}(std::forward<R>(r), std::get<I>(std::forward<This>(thiz).args_)...);
64 std::tuple<Args...> args_;
Definition: range_adaptor.hpp:25
constexpr range_adaptor(T &&... args) noexcept(conjunction< std::is_nothrow_constructible< Args, T >... >::value)
Definition: range_adaptor.hpp:34
std::integral_constant< bool, v > bool_constant
Definition: bool_constant.hpp:19
Definition: matrix.hpp:495
Definition: directory.h:12
constexpr VCCC_INLINE_OR_STATIC detail::element_niebloid< 1 > value
Definition: key_value.hpp:35
Definition: conjunction.hpp:22
Definition: different_from.hpp:21
Determines whether INVOKE(std::declval<Fn>(), std::declval<ArgTypes>()...) is well formed when treate...
Definition: is_invocable.hpp:77
helper base class template for defining a range adaptor closure object
Definition: range_adaptor_closure.hpp:96