Chris@16: /////////////////////////////////////////////////////////////////////////////// Chris@16: /// \file generate_by_value.hpp Chris@16: /// Contains definition of by_value_generator_\<\> class template. Chris@16: // Chris@16: // Copyright 2008 Eric Niebler. Distributed under the Boost Chris@16: // Software License, Version 1.0. (See accompanying file Chris@16: // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 1> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list1 Chris@16: src_args; Chris@16: typedef Chris@16: list1< Chris@16: typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 1> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list1 Chris@16: src_args; Chris@16: typedef Chris@16: list1< Chris@16: typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 2> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list2 Chris@16: src_args; Chris@16: typedef Chris@16: list2< Chris@16: typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 2> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list2 Chris@16: src_args; Chris@16: typedef Chris@16: list2< Chris@16: typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 3> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list3 Chris@16: src_args; Chris@16: typedef Chris@16: list3< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 3> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list3 Chris@16: src_args; Chris@16: typedef Chris@16: list3< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 4> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list4 Chris@16: src_args; Chris@16: typedef Chris@16: list4< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 4> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list4 Chris@16: src_args; Chris@16: typedef Chris@16: list4< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 5> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list5 Chris@16: src_args; Chris@16: typedef Chris@16: list5< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 5> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list5 Chris@16: src_args; Chris@16: typedef Chris@16: list5< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 6> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list6 Chris@16: src_args; Chris@16: typedef Chris@16: list6< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 6> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list6 Chris@16: src_args; Chris@16: typedef Chris@16: list6< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 7> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list7 Chris@16: src_args; Chris@16: typedef Chris@16: list7< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 7> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list7 Chris@16: src_args; Chris@16: typedef Chris@16: list7< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 8> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list8 Chris@16: src_args; Chris@16: typedef Chris@16: list8< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 , e.child7 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 8> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list8 Chris@16: src_args; Chris@16: typedef Chris@16: list8< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 , e.child7 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 9> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list9 Chris@16: src_args; Chris@16: typedef Chris@16: list9< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 , e.child7 , e.child8 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 9> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list9 Chris@16: src_args; Chris@16: typedef Chris@16: list9< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 , e.child7 , e.child8 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::expr, 10> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list10 Chris@16: src_args; Chris@16: typedef Chris@16: list10< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::expr src_type; Chris@16: typedef proto::expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 , e.child7 , e.child8 , e.child9 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: }; Chris@16: template Chris@16: struct by_value_generator_< Chris@16: proto::basic_expr, 10> Chris@16: > Chris@16: { Chris@16: typedef Chris@16: list10 Chris@16: src_args; Chris@16: typedef Chris@16: list10< Chris@16: typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type , typename uncvref::type Chris@16: > Chris@16: dst_args; Chris@16: typedef proto::basic_expr src_type; Chris@16: typedef proto::basic_expr type; Chris@16: BOOST_FORCEINLINE Chris@16: static type const call(src_type const &e) Chris@16: { Chris@16: type that = { Chris@16: e.child0 , e.child1 , e.child2 , e.child3 , e.child4 , e.child5 , e.child6 , e.child7 , e.child8 , e.child9 Chris@16: }; Chris@16: return that; Chris@16: } Chris@16: };