tlx
tlx::meta_detail Namespace Reference

Classes

class  CallForRangeImpl
 helper for call_for_range: general recursive case More...
 
class  CallForRangeImpl< Index, 0, Functor >
 helper for call_for_range: base case More...
 
struct  make_index_sequence_helper
 
struct  make_index_sequence_helper< 0, Indexes... >
 
class  VMapForRangeImpl
 helper for vmap_for_range: general recursive case More...
 
class  VMapForRangeImpl< Index, 0, Functor >
 helper for vmap_for_range: base case More...
 

Functions

template<typename Functor , typename Tuple , std::size_t... Is>
auto apply_tuple_impl (Functor &&f, Tuple &&t, index_sequence< Is... >)
 
template<typename Functor , typename Arg >
void call_foreach_impl (Functor &&f, Arg &&arg)
 helper for call_foreach: base case More...
 
template<typename Functor , typename Arg , typename... MoreArgs>
void call_foreach_impl (Functor &&f, Arg &&arg, MoreArgs &&...rest)
 helper for call_foreach: general recursive case More...
 
template<typename Functor , typename Tuple , std::size_t... Is>
void call_foreach_tuple_impl (Functor &&f, Tuple &&t, index_sequence< Is... >)
 helper for call_foreach_tuple More...
 
template<typename Functor , typename Tuple , std::size_t... Is>
void call_foreach_tuple_with_index_impl (Functor &&f, Tuple &&t, index_sequence< Is... >)
 helper for call_foreach_tuple_with_index More...
 
template<size_t Index, typename Functor , typename Arg >
void call_foreach_with_index_impl (Functor &&f, Arg &&arg)
 helper for call_foreach_with_index: base case More...
 
template<size_t Index, typename Functor , typename Arg , typename... MoreArgs>
void call_foreach_with_index_impl (Functor &&f, Arg &&arg, MoreArgs &&...rest)
 helper for call_foreach_with_index: general recursive case More...
 
template<typename Reduce , typename Initial , typename Arg >
auto fold_left_impl (Reduce &&r, Initial &&init, Arg &&arg)
 helper for fold_left(): base case More...
 
template<typename Reduce , typename Initial , typename Arg , typename... MoreArgs>
auto fold_left_impl (Reduce &&r, Initial &&init, Arg &&arg, MoreArgs &&...rest)
 helper for fold_left(): general recursive case More...
 
template<typename Reduce , typename Initial , typename Tuple , std::size_t... Is>
auto fold_left_tuple_impl (Reduce &&r, Initial &&init, Tuple &&t, index_sequence< Is... >)
 helper for fold_left_tuple: forwards tuple entries More...
 
template<typename Reduce , typename Initial , typename Arg >
auto fold_right_impl (Reduce &&r, Initial &&init, Arg &&arg)
 helper for fold_right: base case More...
 
template<typename Reduce , typename Initial , typename Arg , typename... MoreArgs>
auto fold_right_impl (Reduce &&r, Initial &&init, Arg &&arg, MoreArgs &&...rest)
 helper for fold_right: general recursive case More...
 
template<typename Reduce , typename Initial , typename Tuple , std::size_t... Is>
auto fold_right_tuple_impl (Reduce &&r, Initial &&init, Tuple &&t, index_sequence< Is... >)
 helper for fold_right_tuple: forwards tuple entries More...
 
static auto call_chain ()
 Base case for the chaining of functors: zero functors, returns the identity. More...
 
template<typename Functor >
auto call_chain (const Functor &functor)
 Base case for the chaining of functors. More...
 
template<typename Functor , typename... MoreFunctors>
auto call_chain (const Functor &functor, const MoreFunctors &...rest)
 Recursive case for the chaining of functors. More...
 
template<typename Functor >
auto call_stack (const Functor &functor)
 Base case for the chaining of functors. More...
 
template<typename Functor , typename... MoreFunctors>
auto call_stack (const Functor &functor, const MoreFunctors &...rest)
 Recursive case for the chaining of functors. More...
 
template<typename Functor , typename Arg >
auto vmap_foreach_impl (Functor &&f, Arg &&arg)
 helper for vmap_foreach: base case More...
 
template<typename Functor , typename Arg , typename... MoreArgs>
auto vmap_foreach_impl (Functor &&f, Arg &&arg, MoreArgs &&...rest)
 helper for vmap_foreach: general recursive case More...
 
template<typename Functor , typename Tuple , std::size_t... Is>
auto vmap_foreach_tuple_impl (Functor &&f, Tuple &&t, index_sequence< Is... >)
 helper for vmap_foreach_tuple: forwards tuple entries More...
 
template<typename Functor , typename Tuple , std::size_t... Is>
auto vmap_foreach_tuple_with_index_impl (Functor &&f, Tuple &&t, index_sequence< Is... >)
 helper for vmap_foreach_tuple_with_index: forwards tuple entries More...
 
template<size_t Index, typename Functor , typename Arg >
auto vmap_foreach_with_index_impl (Functor &&f, Arg &&arg)
 helper for vmap_foreach_with_index: base case More...
 
template<size_t Index, typename Functor , typename Arg , typename... MoreArgs>
auto vmap_foreach_with_index_impl (Functor &&f, Arg &&arg, MoreArgs &&...rest)
 helper for vmap_foreach_with_index: general recursive case More...
 

Function Documentation

auto tlx::meta_detail::apply_tuple_impl ( Functor &&  f,
Tuple &&  t,
index_sequence< Is... >   
)

Definition at line 31 of file apply_tuple.hpp.

static auto tlx::meta_detail::call_chain ( )
inlinestatic

Base case for the chaining of functors: zero functors, returns the identity.

Definition at line 34 of file function_chain.hpp.

auto tlx::meta_detail::call_chain ( const Functor &  functor)

Base case for the chaining of functors.

The one functor receives an input element

Parameters
functorfunctor that represents the chain end.

Definition at line 47 of file function_chain.hpp.

auto tlx::meta_detail::call_chain ( const Functor &  functor,
const MoreFunctors &...  rest 
)

Recursive case for the chaining of functors.

The first functor receives an input element, and the remaining chain is applied to the result.

Parameters
functorCurrent functor to be chained.
restRemaining functors.

Definition at line 64 of file function_chain.hpp.

void tlx::meta_detail::call_foreach_impl ( Functor &&  f,
Arg &&  arg 
)

helper for call_foreach: base case

Definition at line 29 of file call_foreach.hpp.

void tlx::meta_detail::call_foreach_impl ( Functor &&  f,
Arg &&  arg,
MoreArgs &&...  rest 
)

helper for call_foreach: general recursive case

Definition at line 35 of file call_foreach.hpp.

void tlx::meta_detail::call_foreach_tuple_impl ( Functor &&  f,
Tuple &&  t,
index_sequence< Is... >   
)

helper for call_foreach_tuple

Definition at line 34 of file call_foreach_tuple.hpp.

void tlx::meta_detail::call_foreach_tuple_with_index_impl ( Functor &&  f,
Tuple &&  t,
index_sequence< Is... >   
)

helper for call_foreach_tuple_with_index

Definition at line 34 of file call_foreach_tuple_with_index.hpp.

void tlx::meta_detail::call_foreach_with_index_impl ( Functor &&  f,
Arg &&  arg 
)

helper for call_foreach_with_index: base case

Definition at line 33 of file call_foreach_with_index.hpp.

void tlx::meta_detail::call_foreach_with_index_impl ( Functor &&  f,
Arg &&  arg,
MoreArgs &&...  rest 
)

helper for call_foreach_with_index: general recursive case

Definition at line 39 of file call_foreach_with_index.hpp.

auto tlx::meta_detail::call_stack ( const Functor &  functor)

Base case for the chaining of functors.

The last functor receives an input element, no emitter and should have no return type. It should therefore store the input parameter externally.

Parameters
functorFunctor that represents the chain end.

Definition at line 42 of file function_stack.hpp.

auto tlx::meta_detail::call_stack ( const Functor &  functor,
const MoreFunctors &...  rest 
)

Recursive case for the chaining of functors.

The given functor receives an input element, an emitter and should have no return type. The emitter will be built using the chain of remaining functors.

Parameters
functorCurrent functor to be chained.
restRemaining functors.

Definition at line 61 of file function_stack.hpp.

auto tlx::meta_detail::fold_left_impl ( Reduce &&  r,
Initial &&  init,
Arg &&  arg 
)

helper for fold_left(): base case

Definition at line 30 of file fold_left.hpp.

auto tlx::meta_detail::fold_left_impl ( Reduce &&  r,
Initial &&  init,
Arg &&  arg,
MoreArgs &&...  rest 
)

helper for fold_left(): general recursive case

Definition at line 37 of file fold_left.hpp.

auto tlx::meta_detail::fold_left_tuple_impl ( Reduce &&  r,
Initial &&  init,
Tuple &&  t,
index_sequence< Is... >   
)

helper for fold_left_tuple: forwards tuple entries

Definition at line 31 of file fold_left_tuple.hpp.

auto tlx::meta_detail::fold_right_impl ( Reduce &&  r,
Initial &&  init,
Arg &&  arg 
)

helper for fold_right: base case

Definition at line 30 of file fold_right.hpp.

auto tlx::meta_detail::fold_right_impl ( Reduce &&  r,
Initial &&  init,
Arg &&  arg,
MoreArgs &&...  rest 
)

helper for fold_right: general recursive case

Definition at line 37 of file fold_right.hpp.

auto tlx::meta_detail::fold_right_tuple_impl ( Reduce &&  r,
Initial &&  init,
Tuple &&  t,
index_sequence< Is... >   
)

helper for fold_right_tuple: forwards tuple entries

Definition at line 31 of file fold_right_tuple.hpp.

auto tlx::meta_detail::vmap_foreach_impl ( Functor &&  f,
Arg &&  arg 
)

helper for vmap_foreach: base case

Definition at line 31 of file vmap_foreach.hpp.

auto tlx::meta_detail::vmap_foreach_impl ( Functor &&  f,
Arg &&  arg,
MoreArgs &&...  rest 
)

helper for vmap_foreach: general recursive case

Definition at line 38 of file vmap_foreach.hpp.

auto tlx::meta_detail::vmap_foreach_tuple_impl ( Functor &&  f,
Tuple &&  t,
index_sequence< Is... >   
)

helper for vmap_foreach_tuple: forwards tuple entries

Definition at line 32 of file vmap_foreach_tuple.hpp.

auto tlx::meta_detail::vmap_foreach_tuple_with_index_impl ( Functor &&  f,
Tuple &&  t,
index_sequence< Is... >   
)

helper for vmap_foreach_tuple_with_index: forwards tuple entries

Definition at line 34 of file vmap_foreach_tuple_with_index.hpp.

auto tlx::meta_detail::vmap_foreach_with_index_impl ( Functor &&  f,
Arg &&  arg 
)

helper for vmap_foreach_with_index: base case

Definition at line 35 of file vmap_foreach_with_index.hpp.

auto tlx::meta_detail::vmap_foreach_with_index_impl ( Functor &&  f,
Arg &&  arg,
MoreArgs &&...  rest 
)

helper for vmap_foreach_with_index: general recursive case

Definition at line 42 of file vmap_foreach_with_index.hpp.