19 #ifndef INCLUDED_Fold_h_GUID_63DEE2B1_33B4_47B3_1289_B30F2B5BEA6B
20 #define INCLUDED_Fold_h_GUID_63DEE2B1_33B4_47B3_1289_B30F2B5BEA6B
39 template <
typename List,
typename State,
typename Fun>
struct fold_;
42 template <
typename List,
typename State,
typename Fun>
44 : fold_<tail<List>, t_<apply<Fun, State, head<List>>>, Fun> {};
47 template <
typename State,
typename Fun>
48 struct fold_<list<>, State, Fun> {
56 template <
typename List,
typename State,
typename Fun>
62 #endif // INCLUDED_Fold_h_GUID_63DEE2B1_33B4_47B3_1289_B30F2B5BEA6B
The main namespace for all C++ elements of the framework, internal and external.
typename T::type t_
A convenience alias template to extract the nested type within the supplied T.
t_< detail::fold_< List, State, Fun >> fold
Fold the list (right) with the given alias class and initial state.