enumerate.hpp
Go to the documentation of this file.
constexpr auto count(InitT init=InitT{0}, StepT step=StepT{1}) -> count_t< InitT, StepT >
Generator transducer produces a sequence:
Definition: count.hpp:78
const enumerate_t< std::size_t > enumerate
Equivalent to enumerate_from(std::size_t{}).
auto state_unwrap(T &&s) -> decltype(state_traits_t< T >::unwrap(std::forward< T >(s)))
Convenience function for calling state_traits::unwrap
Definition: state_traits.hpp:136
auto constantly(T &&value) -> constantly_t< estd::decay_t< T > >
Similar to clojure.core/constantly.
Definition: constantly.hpp:56
auto state_data(T &&s, D &&d) -> decltype(state_traits_t< T >::data(std::forward< T >(s), std::forward< D >(d)))
Convenience function for calling state_traits::data
Definition: state_traits.hpp:127
Utility to write simple transducers easily.
Definition: transducer_impl.hpp:60
constexpr auto enumerate_from(IntegralT &&init) -> enumerate_t< estd::decay_t< IntegralT > >
Transducer that given a sequence:
Definition: enumerate.hpp:102
auto wrap_state(StateT &&next, DataT &&data=DataT{}) -> state_wrapper< TagT, estd::decay_t< StateT >, estd::decay_t< DataT > >
Given a tag TagT and a state next and associated data, returns a state_wrapper instance.
Definition: state_wrapper.hpp:104