[#before_5_2_2] ['Definitions before section 5.2.2.] #include #include #include using namespace boost::metaparse; using exp_parser1 = build_parser; #include using exp_parser2 = build_parser>; #include using exp_parser3 = build_parser>>; #include #include using exp_parser4 = build_parser, token>, token>>; #include using int_token = token; using plus_token = token>; using exp_parser5 = build_parser>; #include #include #include template struct eval_plus : boost::mpl::plus< typename boost::mpl::at_c::type, typename boost::mpl::at_c::type > {}; #include using exp_parser6 = build_parser< transform< sequence, boost::mpl::quote1 > >; #include using exp_parser7 = build_parser< sequence< int_token, /* The first */ repeated> /* The "+ " elements */ > >; using temp_result = exp_parser7::apply::type; #include using vector_of_numbers = boost::mpl::vector< boost::mpl::int_<2>, boost::mpl::int_<5>, boost::mpl::int_<6> >; template struct sum_vector : boost::mpl::fold< Vector, boost::mpl::int_<0>, boost::mpl::lambda< boost::mpl::plus >::type > {}; template struct sum_items : boost::mpl::plus< Sum, typename boost::mpl::at_c::type > {};