Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r71735 - in trunk: boost/proto boost/proto/detail boost/proto/detail/preprocessed libs/proto/preprocess
From: eric_at_[hidden]
Date: 2011-05-05 05:41:15


Author: eric_niebler
Date: 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
New Revision: 71735
URL: http://svn.boost.org/trac/boost/changeset/71735

Log:
pre-preprocess expr, basic_expr and detail::funop
Added:
   trunk/boost/proto/detail/expr.hpp
      - copied, changed from r71718, /trunk/boost/proto/detail/expr0.hpp
   trunk/boost/proto/detail/expr_funop.hpp
      - copied, changed from r71718, /trunk/boost/proto/detail/expr1.hpp
   trunk/boost/proto/detail/preprocessed/
   trunk/boost/proto/detail/preprocessed/basic_expr.hpp (contents, props changed)
   trunk/boost/proto/detail/preprocessed/expr.hpp (contents, props changed)
   trunk/boost/proto/detail/preprocessed/expr_variadic.hpp (contents, props changed)
   trunk/boost/proto/detail/preprocessed/funop.hpp (contents, props changed)
   trunk/libs/proto/preprocess/
   trunk/libs/proto/preprocess/preprocess_proto.cpp (contents, props changed)
   trunk/libs/proto/preprocess/wave.cfg (contents, props changed)
Removed:
   trunk/boost/proto/detail/expr0.hpp
   trunk/boost/proto/detail/expr1.hpp
Text files modified:
   trunk/boost/proto/detail/expr.hpp | 204 +++++++++++++++------------------------
   trunk/boost/proto/detail/expr_funop.hpp | 56 +++++-----
   trunk/boost/proto/detail/funop.hpp | 64 ++++++++----
   trunk/boost/proto/expr.hpp | 34 +-----
   trunk/boost/proto/proto_fwd.hpp | 8 +
   5 files changed, 164 insertions(+), 202 deletions(-)

Copied: trunk/boost/proto/detail/expr.hpp (from r71718, /trunk/boost/proto/detail/expr0.hpp)
==============================================================================
--- /trunk/boost/proto/detail/expr0.hpp (original)
+++ trunk/boost/proto/detail/expr.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -1,137 +1,88 @@
-///////////////////////////////////////////////////////////////////////////////
-// expr.hpp
-// Contains definition of expr\<\> class template.
-//
-// Copyright 2008 Eric Niebler. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+#if !defined(BOOST_PROTO_DONT_USE_PREPROCESSED_FILES)
 
-#ifndef BOOST_PP_IS_ITERATING
-#error Do not include this file directly
-#endif
+ #ifndef BOOST_NO_VARIADIC_TEMPLATES
+ #include <boost/proto/detail/preprocessed/expr_variadic.hpp>
+ #else
+ #include <boost/proto/detail/preprocessed/expr.hpp>
+ #endif
 
-#define ARG_COUNT BOOST_PP_MAX(1, BOOST_PP_ITERATION())
+#elif !defined(BOOST_PP_IS_ITERATING)
 
- /// \brief Simplified representation of a node in an expression tree.
- ///
- /// \c proto::basic_expr\<\> is a node in an expression template tree. It
- /// is a container for its child sub-trees. It also serves as
- /// the terminal nodes of the tree.
- ///
- /// \c Tag is type that represents the operation encoded by
- /// this expression. It is typically one of the structs
- /// in the \c boost::proto::tag namespace, but it doesn't
- /// have to be.
- ///
- /// \c Args is a type list representing the type of the children
- /// of this expression. It is an instantiation of one
- /// of \c proto::list1\<\>, \c proto::list2\<\>, etc. The
- /// child types must all themselves be either \c expr\<\>
- /// or <tt>proto::expr\<\>&</tt>. If \c Args is an
- /// instantiation of \c proto::term\<\> then this
- /// \c expr\<\> type represents a terminal expression;
- /// the parameter to the \c proto::term\<\> template
- /// represents the terminal's value type.
- ///
- /// \c Arity is an integral constant representing the number of child
- /// nodes this node contains. If \c Arity is 0, then this
- /// node is a terminal.
- ///
- /// \c proto::basic_expr\<\> is a valid Fusion random-access sequence, where
- /// the elements of the sequence are the child expressions.
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- template<typename Tag, typename Arg0>
- struct basic_expr<Tag, term<Arg0>, 0>
- #else
- template<typename Tag BOOST_PP_ENUM_TRAILING_PARAMS(ARG_COUNT, typename Arg)>
- struct basic_expr<Tag, BOOST_PP_CAT(list, BOOST_PP_ITERATION())<BOOST_PP_ENUM_PARAMS(ARG_COUNT, Arg)>, BOOST_PP_ITERATION() >
+ // Generate variadic versions of expr
+ #if defined(__WAVE__) && defined(BOOST_PROTO_CREATE_PREPROCESSED_FILES)
+ #pragma wave option(preserve: 2, line: 0, output: "preprocessed/expr_variadic.hpp")
     #endif
- {
- typedef Tag proto_tag;
- BOOST_STATIC_CONSTANT(long, proto_arity_c = BOOST_PP_ITERATION());
- typedef mpl::long_<BOOST_PP_ITERATION() > proto_arity;
- typedef basic_expr proto_base_expr;
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- typedef term<Arg0> proto_args;
- #else
- typedef BOOST_PP_CAT(list, BOOST_PP_ITERATION())<BOOST_PP_ENUM_PARAMS(ARG_COUNT, Arg)> proto_args;
- #endif
- typedef basic_expr proto_grammar;
- typedef default_domain proto_domain;
- typedef default_generator proto_generator;
- typedef proto::tag::proto_expr fusion_tag;
- typedef basic_expr proto_derived_expr;
- typedef void proto_is_expr_; /**< INTERNAL ONLY */
 
- BOOST_PP_REPEAT(ARG_COUNT, BOOST_PROTO_CHILD, ~)
- BOOST_PP_REPEAT_FROM_TO(ARG_COUNT, BOOST_PROTO_MAX_ARITY, BOOST_PROTO_VOID, ~)
+ ///////////////////////////////////////////////////////////////////////////////
+ /// \file expr_variadic.hpp
+ /// Contains definition of expr\<\> class template.
+ //
+ // Copyright 2008 Eric Niebler. Distributed under the Boost
+ // Software License, Version 1.0. (See accompanying file
+ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
 
- /// \return *this
- ///
- basic_expr const &proto_base() const
- {
- return *this;
- }
+ #if defined(__WAVE__) && defined(BOOST_PROTO_CREATE_PREPROCESSED_FILES)
+ #pragma wave option(preserve: 1)
+ #endif
 
- /// \overload
- ///
- basic_expr &proto_base()
- {
- return *this;
- }
+ /// INTERNAL ONLY
+ ///
+ #define BOOST_PROTO_CHILD(Z, N, DATA) \
+ typedef BOOST_PP_CAT(Arg, N) BOOST_PP_CAT(proto_child, N); \
+ BOOST_PP_CAT(proto_child, N) BOOST_PP_CAT(child, N); \
+ /**< INTERNAL ONLY */
 
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \return A new \c expr\<\> object initialized with the specified
- /// arguments.
- ///
- template<typename A0>
- static basic_expr const make(A0 &a0)
- {
- return detail::make_terminal(a0, static_cast<basic_expr *>(0), static_cast<proto_args *>(0));
- }
+ /// INTERNAL ONLY
+ ///
+ #define BOOST_PROTO_VOID(Z, N, DATA) \
+ typedef void BOOST_PP_CAT(proto_child, N); \
+ /**< INTERNAL ONLY */
+
+ // The expr<> specializations are actually defined here.
+ #define BOOST_PROTO_DEFINE_TERMINAL
+ #define BOOST_PP_ITERATION_PARAMS_1 \
+ (3, (0, 0, <boost/proto/detail/expr.hpp>))
+ #include BOOST_PP_ITERATE()
 
- /// \overload
- ///
- template<typename A0>
- static basic_expr const make(A0 const &a0)
- {
- return detail::make_terminal(a0, static_cast<basic_expr *>(0), static_cast<proto_args *>(0));
- }
- #else
- /// \return A new \c expr\<\> object initialized with the specified
- /// arguments.
- ///
- template<BOOST_PP_ENUM_PARAMS(ARG_COUNT, typename A)>
- static basic_expr const make(BOOST_PP_ENUM_BINARY_PARAMS(ARG_COUNT, A, const &a))
- {
- basic_expr that = {BOOST_PP_ENUM_PARAMS(ARG_COUNT, a)};
- return that;
- }
- #endif
+ #undef BOOST_PROTO_DEFINE_TERMINAL
+ #define BOOST_PP_ITERATION_PARAMS_1 \
+ (3, (1, BOOST_PROTO_MAX_ARITY, <boost/proto/detail/expr.hpp>))
+ #include BOOST_PP_ITERATE()
 
- #if 1 == BOOST_PP_ITERATION()
- /// If \c Tag is \c boost::proto::tag::address_of and \c proto_child0 is
- /// <tt>T&</tt>, then \c address_of_hack_type_ is <tt>T*</tt>.
- /// Otherwise, it is some undefined type.
- typedef typename detail::address_of_hack<Tag, proto_child0>::type address_of_hack_type_;
+ // Generate non-variadic versions of expr
+ #if defined(__WAVE__) && defined(BOOST_PROTO_CREATE_PREPROCESSED_FILES)
+ #define BOOST_NO_VARIADIC_TEMPLATES
+ #pragma wave option(preserve: 2, line: 0, output: "preprocessed/expr.hpp")
+
+ ///////////////////////////////////////////////////////////////////////////////
+ /// \file expr.hpp
+ /// Contains definition of expr\<\> class template.
+ //
+ // Copyright 2008 Eric Niebler. Distributed under the Boost
+ // Software License, Version 1.0. (See accompanying file
+ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+ #pragma wave option(preserve: 1)
+
+ // The expr<> specializations are actually defined here.
+ #define BOOST_PROTO_DEFINE_TERMINAL
+ #define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 0, <boost/proto/detail/expr.hpp>))
+ #include BOOST_PP_ITERATE()
+
+ #undef BOOST_PROTO_DEFINE_TERMINAL
+ #define BOOST_PP_ITERATION_PARAMS_1 (3, (1, BOOST_PROTO_MAX_ARITY, <boost/proto/detail/expr.hpp>))
+ #include BOOST_PP_ITERATE()
 
- /// \return The address of <tt>this->child0</tt> if \c Tag is
- /// \c boost::proto::tag::address_of. Otherwise, this function will
- /// fail to compile.
- ///
- /// \attention Proto overloads <tt>operator&</tt>, which means that
- /// proto-ified objects cannot have their addresses taken, unless we use
- /// the following hack to make \c &x implicitly convertible to \c X*.
- operator address_of_hack_type_() const
- {
- return boost::addressof(this->child0);
- }
- #else
- /// INTERNAL ONLY
- ///
- typedef detail::not_a_valid_type address_of_hack_type_;
+ #pragma wave option(output: null)
+ #undef BOOST_NO_VARIADIC_TEMPLATES
     #endif
- };
+
+ #undef BOOST_PROTO_CHILD
+ #undef BOOST_PROTO_VOID
+
+#else
+
+ #define ARG_COUNT BOOST_PP_MAX(1, BOOST_PP_ITERATION())
 
     /// \brief Representation of a node in an expression tree.
     ///
@@ -432,7 +383,7 @@
             typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
         };
 
-#ifndef BOOST_NO_VARIADIC_TEMPLATES
+ #ifndef BOOST_NO_VARIADIC_TEMPLATES
         /// \overload
         ///
         template<typename ...A>
@@ -469,7 +420,7 @@
         }
     #endif
 
-#else // BOOST_NO_VARIADIC_TEMPLATES
+ #else // BOOST_NO_VARIADIC_TEMPLATES
 
         /// Function call
         ///
@@ -492,10 +443,13 @@
         }
     #endif
 
- #define BOOST_PP_ITERATION_PARAMS_2 (3, (1, BOOST_PP_DEC(BOOST_PROTO_MAX_FUNCTION_CALL_ARITY), <boost/proto/detail/expr1.hpp>))
+ #define BOOST_PP_ITERATION_PARAMS_2 \
+ (3, (1, BOOST_PP_DEC(BOOST_PROTO_MAX_FUNCTION_CALL_ARITY), <boost/proto/detail/expr_funop.hpp>))
     #include BOOST_PP_ITERATE()
 
 #endif
     };
 
 #undef ARG_COUNT
+
+#endif

Deleted: trunk/boost/proto/detail/expr0.hpp
==============================================================================
--- trunk/boost/proto/detail/expr0.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
+++ (empty file)
@@ -1,501 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-// expr.hpp
-// Contains definition of expr\<\> class template.
-//
-// Copyright 2008 Eric Niebler. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-
-#ifndef BOOST_PP_IS_ITERATING
-#error Do not include this file directly
-#endif
-
-#define ARG_COUNT BOOST_PP_MAX(1, BOOST_PP_ITERATION())
-
- /// \brief Simplified representation of a node in an expression tree.
- ///
- /// \c proto::basic_expr\<\> is a node in an expression template tree. It
- /// is a container for its child sub-trees. It also serves as
- /// the terminal nodes of the tree.
- ///
- /// \c Tag is type that represents the operation encoded by
- /// this expression. It is typically one of the structs
- /// in the \c boost::proto::tag namespace, but it doesn't
- /// have to be.
- ///
- /// \c Args is a type list representing the type of the children
- /// of this expression. It is an instantiation of one
- /// of \c proto::list1\<\>, \c proto::list2\<\>, etc. The
- /// child types must all themselves be either \c expr\<\>
- /// or <tt>proto::expr\<\>&</tt>. If \c Args is an
- /// instantiation of \c proto::term\<\> then this
- /// \c expr\<\> type represents a terminal expression;
- /// the parameter to the \c proto::term\<\> template
- /// represents the terminal's value type.
- ///
- /// \c Arity is an integral constant representing the number of child
- /// nodes this node contains. If \c Arity is 0, then this
- /// node is a terminal.
- ///
- /// \c proto::basic_expr\<\> is a valid Fusion random-access sequence, where
- /// the elements of the sequence are the child expressions.
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- template<typename Tag, typename Arg0>
- struct basic_expr<Tag, term<Arg0>, 0>
- #else
- template<typename Tag BOOST_PP_ENUM_TRAILING_PARAMS(ARG_COUNT, typename Arg)>
- struct basic_expr<Tag, BOOST_PP_CAT(list, BOOST_PP_ITERATION())<BOOST_PP_ENUM_PARAMS(ARG_COUNT, Arg)>, BOOST_PP_ITERATION() >
- #endif
- {
- typedef Tag proto_tag;
- BOOST_STATIC_CONSTANT(long, proto_arity_c = BOOST_PP_ITERATION());
- typedef mpl::long_<BOOST_PP_ITERATION() > proto_arity;
- typedef basic_expr proto_base_expr;
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- typedef term<Arg0> proto_args;
- #else
- typedef BOOST_PP_CAT(list, BOOST_PP_ITERATION())<BOOST_PP_ENUM_PARAMS(ARG_COUNT, Arg)> proto_args;
- #endif
- typedef basic_expr proto_grammar;
- typedef default_domain proto_domain;
- typedef default_generator proto_generator;
- typedef proto::tag::proto_expr fusion_tag;
- typedef basic_expr proto_derived_expr;
- typedef void proto_is_expr_; /**< INTERNAL ONLY */
-
- BOOST_PP_REPEAT(ARG_COUNT, BOOST_PROTO_CHILD, ~)
- BOOST_PP_REPEAT_FROM_TO(ARG_COUNT, BOOST_PROTO_MAX_ARITY, BOOST_PROTO_VOID, ~)
-
- /// \return *this
- ///
- basic_expr const &proto_base() const
- {
- return *this;
- }
-
- /// \overload
- ///
- basic_expr &proto_base()
- {
- return *this;
- }
-
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \return A new \c expr\<\> object initialized with the specified
- /// arguments.
- ///
- template<typename A0>
- static basic_expr const make(A0 &a0)
- {
- return detail::make_terminal(a0, static_cast<basic_expr *>(0), static_cast<proto_args *>(0));
- }
-
- /// \overload
- ///
- template<typename A0>
- static basic_expr const make(A0 const &a0)
- {
- return detail::make_terminal(a0, static_cast<basic_expr *>(0), static_cast<proto_args *>(0));
- }
- #else
- /// \return A new \c expr\<\> object initialized with the specified
- /// arguments.
- ///
- template<BOOST_PP_ENUM_PARAMS(ARG_COUNT, typename A)>
- static basic_expr const make(BOOST_PP_ENUM_BINARY_PARAMS(ARG_COUNT, A, const &a))
- {
- basic_expr that = {BOOST_PP_ENUM_PARAMS(ARG_COUNT, a)};
- return that;
- }
- #endif
-
- #if 1 == BOOST_PP_ITERATION()
- /// If \c Tag is \c boost::proto::tag::address_of and \c proto_child0 is
- /// <tt>T&</tt>, then \c address_of_hack_type_ is <tt>T*</tt>.
- /// Otherwise, it is some undefined type.
- typedef typename detail::address_of_hack<Tag, proto_child0>::type address_of_hack_type_;
-
- /// \return The address of <tt>this->child0</tt> if \c Tag is
- /// \c boost::proto::tag::address_of. Otherwise, this function will
- /// fail to compile.
- ///
- /// \attention Proto overloads <tt>operator&</tt>, which means that
- /// proto-ified objects cannot have their addresses taken, unless we use
- /// the following hack to make \c &x implicitly convertible to \c X*.
- operator address_of_hack_type_() const
- {
- return boost::addressof(this->child0);
- }
- #else
- /// INTERNAL ONLY
- ///
- typedef detail::not_a_valid_type address_of_hack_type_;
- #endif
- };
-
- /// \brief Representation of a node in an expression tree.
- ///
- /// \c proto::expr\<\> is a node in an expression template tree. It
- /// is a container for its child sub-trees. It also serves as
- /// the terminal nodes of the tree.
- ///
- /// \c Tag is type that represents the operation encoded by
- /// this expression. It is typically one of the structs
- /// in the \c boost::proto::tag namespace, but it doesn't
- /// have to be.
- ///
- /// \c Args is a type list representing the type of the children
- /// of this expression. It is an instantiation of one
- /// of \c proto::list1\<\>, \c proto::list2\<\>, etc. The
- /// child types must all themselves be either \c expr\<\>
- /// or <tt>proto::expr\<\>&</tt>. If \c Args is an
- /// instantiation of \c proto::term\<\> then this
- /// \c expr\<\> type represents a terminal expression;
- /// the parameter to the \c proto::term\<\> template
- /// represents the terminal's value type.
- ///
- /// \c Arity is an integral constant representing the number of child
- /// nodes this node contains. If \c Arity is 0, then this
- /// node is a terminal.
- ///
- /// \c proto::expr\<\> is a valid Fusion random-access sequence, where
- /// the elements of the sequence are the child expressions.
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- template<typename Tag, typename Arg0>
- struct expr<Tag, term<Arg0>, 0>
- #else
- template<typename Tag BOOST_PP_ENUM_TRAILING_PARAMS(ARG_COUNT, typename Arg)>
- struct expr<Tag, BOOST_PP_CAT(list, BOOST_PP_ITERATION())<BOOST_PP_ENUM_PARAMS(ARG_COUNT, Arg)>, BOOST_PP_ITERATION() >
- #endif
- {
- typedef Tag proto_tag;
- BOOST_STATIC_CONSTANT(long, proto_arity_c = BOOST_PP_ITERATION());
- typedef mpl::long_<BOOST_PP_ITERATION() > proto_arity;
- typedef expr proto_base_expr;
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- typedef term<Arg0> proto_args;
- #else
- typedef BOOST_PP_CAT(list, BOOST_PP_ITERATION())<BOOST_PP_ENUM_PARAMS(ARG_COUNT, Arg)> proto_args;
- #endif
- typedef basic_expr<Tag, proto_args, BOOST_PP_ITERATION() > proto_grammar;
- typedef default_domain proto_domain;
- typedef default_generator proto_generator;
- typedef proto::tag::proto_expr fusion_tag;
- typedef expr proto_derived_expr;
- typedef void proto_is_expr_; /**< INTERNAL ONLY */
-
- BOOST_PP_REPEAT(ARG_COUNT, BOOST_PROTO_CHILD, ~)
- BOOST_PP_REPEAT_FROM_TO(ARG_COUNT, BOOST_PROTO_MAX_ARITY, BOOST_PROTO_VOID, ~)
-
- /// \return *this
- ///
- expr const &proto_base() const
- {
- return *this;
- }
-
- /// \overload
- ///
- expr &proto_base()
- {
- return *this;
- }
-
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \return A new \c expr\<\> object initialized with the specified
- /// arguments.
- ///
- template<typename A0>
- static expr const make(A0 &a0)
- {
- return detail::make_terminal(a0, static_cast<expr *>(0), static_cast<proto_args *>(0));
- }
-
- /// \overload
- ///
- template<typename A0>
- static expr const make(A0 const &a0)
- {
- return detail::make_terminal(a0, static_cast<expr *>(0), static_cast<proto_args *>(0));
- }
- #else
- /// \return A new \c expr\<\> object initialized with the specified
- /// arguments.
- ///
- template<BOOST_PP_ENUM_PARAMS(ARG_COUNT, typename A)>
- static expr const make(BOOST_PP_ENUM_BINARY_PARAMS(ARG_COUNT, A, const &a))
- {
- expr that = {BOOST_PP_ENUM_PARAMS(ARG_COUNT, a)};
- return that;
- }
- #endif
-
- #if 1 == BOOST_PP_ITERATION()
- /// If \c Tag is \c boost::proto::tag::address_of and \c proto_child0 is
- /// <tt>T&</tt>, then \c address_of_hack_type_ is <tt>T*</tt>.
- /// Otherwise, it is some undefined type.
- typedef typename detail::address_of_hack<Tag, proto_child0>::type address_of_hack_type_;
-
- /// \return The address of <tt>this->child0</tt> if \c Tag is
- /// \c boost::proto::tag::address_of. Otherwise, this function will
- /// fail to compile.
- ///
- /// \attention Proto overloads <tt>operator&</tt>, which means that
- /// proto-ified objects cannot have their addresses taken, unless we use
- /// the following hack to make \c &x implicitly convertible to \c X*.
- operator address_of_hack_type_() const
- {
- return boost::addressof(this->child0);
- }
- #else
- /// INTERNAL ONLY
- ///
- typedef detail::not_a_valid_type address_of_hack_type_;
- #endif
-
- /// Assignment
- ///
- /// \param a The rhs.
- /// \return A new \c expr\<\> node representing an assignment of \c that to \c *this.
- proto::expr<
- proto::tag::assign
- , list2<expr &, expr const &>
- , 2
- > const
- operator =(expr const &a)
- {
- proto::expr<
- proto::tag::assign
- , list2<expr &, expr const &>
- , 2
- > that = {*this, a};
- return that;
- }
-
- /// Assignment
- ///
- /// \param a The rhs.
- /// \return A new \c expr\<\> node representing an assignment of \c a to \c *this.
- template<typename A>
- proto::expr<
- proto::tag::assign
- , list2<expr const &, typename result_of::as_child<A>::type>
- , 2
- > const
- operator =(A &a) const
- {
- proto::expr<
- proto::tag::assign
- , list2<expr const &, typename result_of::as_child<A>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
-
- /// \overload
- ///
- template<typename A>
- proto::expr<
- proto::tag::assign
- , list2<expr const &, typename result_of::as_child<A const>::type>
- , 2
- > const
- operator =(A const &a) const
- {
- proto::expr<
- proto::tag::assign
- , list2<expr const &, typename result_of::as_child<A const>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
-
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \overload
- ///
- template<typename A>
- proto::expr<
- proto::tag::assign
- , list2<expr &, typename result_of::as_child<A>::type>
- , 2
- > const
- operator =(A &a)
- {
- proto::expr<
- proto::tag::assign
- , list2<expr &, typename result_of::as_child<A>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
-
- /// \overload
- ///
- template<typename A>
- proto::expr<
- proto::tag::assign
- , list2<expr &, typename result_of::as_child<A const>::type>
- , 2
- > const
- operator =(A const &a)
- {
- proto::expr<
- proto::tag::assign
- , list2<expr &, typename result_of::as_child<A const>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
- #endif
-
- /// Subscript
- ///
- /// \param a The rhs.
- /// \return A new \c expr\<\> node representing \c *this subscripted with \c a.
- template<typename A>
- proto::expr<
- proto::tag::subscript
- , list2<expr const &, typename result_of::as_child<A>::type>
- , 2
- > const
- operator [](A &a) const
- {
- proto::expr<
- proto::tag::subscript
- , list2<expr const &, typename result_of::as_child<A>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
-
- /// \overload
- ///
- template<typename A>
- proto::expr<
- proto::tag::subscript
- , list2<expr const &, typename result_of::as_child<A const>::type>
- , 2
- > const
- operator [](A const &a) const
- {
- proto::expr<
- proto::tag::subscript
- , list2<expr const &, typename result_of::as_child<A const>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
-
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \overload
- ///
- template<typename A>
- proto::expr<
- proto::tag::subscript
- , list2<expr &, typename result_of::as_child<A>::type>
- , 2
- > const
- operator [](A &a)
- {
- proto::expr<
- proto::tag::subscript
- , list2<expr &, typename result_of::as_child<A>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
-
- /// \overload
- ///
- template<typename A>
- proto::expr<
- proto::tag::subscript
- , list2<expr &, typename result_of::as_child<A const>::type>
- , 2
- > const
- operator [](A const &a)
- {
- proto::expr<
- proto::tag::subscript
- , list2<expr &, typename result_of::as_child<A const>::type>
- , 2
- > that = {*this, proto::as_child(a)};
- return that;
- }
- #endif
-
- /// Encodes the return type of \c expr\<\>::operator(), for use with \c boost::result_of\<\>
- ///
- template<typename Sig>
- struct result
- {
- typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
- };
-
-#ifndef BOOST_NO_VARIADIC_TEMPLATES
- /// \overload
- ///
- template<typename ...A>
- typename result_of::funop<
- expr const(A const &...)
- , expr
- , default_domain
- >::type const
- operator ()(A const &... a) const
- {
- return result_of::funop<
- expr const(A const &...)
- , expr
- , default_domain
- >::call(*this, a...);
- }
-
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \overload
- ///
- template<typename ...A>
- typename result_of::funop<
- expr(A const &...)
- , expr
- , default_domain
- >::type const
- operator ()(A const &... a)
- {
- return result_of::funop<
- expr(A const &...)
- , expr
- , default_domain
- >::call(*this, a...);
- }
- #endif
-
-#else // BOOST_NO_VARIADIC_TEMPLATES
-
- /// Function call
- ///
- /// \return A new \c expr\<\> node representing the function invocation of \c (*this)().
- proto::expr<proto::tag::function, list1<expr const &>, 1> const
- operator ()() const
- {
- proto::expr<proto::tag::function, list1<expr const &>, 1> that = {*this};
- return that;
- }
-
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \overload
- ///
- proto::expr<proto::tag::function, list1<expr &>, 1> const
- operator ()()
- {
- proto::expr<proto::tag::function, list1<expr &>, 1> that = {*this};
- return that;
- }
- #endif
-
- #define BOOST_PP_ITERATION_PARAMS_2 (3, (1, BOOST_PP_DEC(BOOST_PROTO_MAX_FUNCTION_CALL_ARITY), <boost/proto/detail/expr1.hpp>))
- #include BOOST_PP_ITERATE()
-
-#endif
- };
-
-#undef ARG_COUNT

Deleted: trunk/boost/proto/detail/expr1.hpp
==============================================================================
--- trunk/boost/proto/detail/expr1.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
+++ (empty file)
@@ -1,47 +0,0 @@
-///////////////////////////////////////////////////////////////////////////////
-// expr1.hpp
-// Contains definition of expr\<\>::operator() overloads.
-//
-// Copyright 2008 Eric Niebler. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-
-#ifndef BOOST_PP_IS_ITERATING
-#error Do not include this file directly
-#endif
-
-#define N BOOST_PP_ITERATION()
-
- /// \overload
- ///
- template<BOOST_PP_ENUM_PARAMS(N, typename A)>
- typename result_of::BOOST_PP_CAT(funop, N)<
- expr const
- , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::type const
- operator ()(BOOST_PP_ENUM_BINARY_PARAMS(N, A, const &a)) const
- {
- return result_of::BOOST_PP_CAT(funop, N)<
- expr const
- , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::call(*this BOOST_PP_ENUM_TRAILING_PARAMS(N, a));
- }
-
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \overload
- ///
- template<BOOST_PP_ENUM_PARAMS(N, typename A)>
- typename result_of::BOOST_PP_CAT(funop, N)<
- expr
- , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::type const
- operator ()(BOOST_PP_ENUM_BINARY_PARAMS(N, A, const &a))
- {
- return result_of::BOOST_PP_CAT(funop, N)<
- expr
- , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::call(*this BOOST_PP_ENUM_TRAILING_PARAMS(N, a));
- }
- #endif
-
-#undef N

Copied: trunk/boost/proto/detail/expr_funop.hpp (from r71718, /trunk/boost/proto/detail/expr1.hpp)
==============================================================================
--- /trunk/boost/proto/detail/expr1.hpp (original)
+++ trunk/boost/proto/detail/expr_funop.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -6,42 +6,38 @@
 // Software License, Version 1.0. (See accompanying file
 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
 
-#ifndef BOOST_PP_IS_ITERATING
-#error Do not include this file directly
-#endif
-
 #define N BOOST_PP_ITERATION()
 
- /// \overload
- ///
- template<BOOST_PP_ENUM_PARAMS(N, typename A)>
- typename result_of::BOOST_PP_CAT(funop, N)<
- expr const
- , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::type const
- operator ()(BOOST_PP_ENUM_BINARY_PARAMS(N, A, const &a)) const
- {
- return result_of::BOOST_PP_CAT(funop, N)<
+ /// \overload
+ ///
+ template<BOOST_PP_ENUM_PARAMS(N, typename A)>
+ typename result_of::BOOST_PP_CAT(funop, N)<
             expr const
           , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::call(*this BOOST_PP_ENUM_TRAILING_PARAMS(N, a));
- }
+ >::type const
+ operator ()(BOOST_PP_ENUM_BINARY_PARAMS(N, A, const &a)) const
+ {
+ return result_of::BOOST_PP_CAT(funop, N)<
+ expr const
+ , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
+ >::call(*this BOOST_PP_ENUM_TRAILING_PARAMS(N, a));
+ }
 
- #ifdef BOOST_PROTO_DEFINE_TERMINAL
- /// \overload
- ///
- template<BOOST_PP_ENUM_PARAMS(N, typename A)>
- typename result_of::BOOST_PP_CAT(funop, N)<
- expr
- , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::type const
- operator ()(BOOST_PP_ENUM_BINARY_PARAMS(N, A, const &a))
- {
- return result_of::BOOST_PP_CAT(funop, N)<
+ #ifdef BOOST_PROTO_DEFINE_TERMINAL
+ /// \overload
+ ///
+ template<BOOST_PP_ENUM_PARAMS(N, typename A)>
+ typename result_of::BOOST_PP_CAT(funop, N)<
             expr
           , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
- >::call(*this BOOST_PP_ENUM_TRAILING_PARAMS(N, a));
- }
- #endif
+ >::type const
+ operator ()(BOOST_PP_ENUM_BINARY_PARAMS(N, A, const &a))
+ {
+ return result_of::BOOST_PP_CAT(funop, N)<
+ expr
+ , default_domain BOOST_PP_ENUM_TRAILING_PARAMS(N, const A)
+ >::call(*this BOOST_PP_ENUM_TRAILING_PARAMS(N, a));
+ }
+ #endif
 
 #undef N

Modified: trunk/boost/proto/detail/funop.hpp
==============================================================================
--- trunk/boost/proto/detail/funop.hpp (original)
+++ trunk/boost/proto/detail/funop.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -1,22 +1,45 @@
-///////////////////////////////////////////////////////////////////////////////
-// funop.hpp
-// Contains definition of funop[n]\<\> class template.
-//
-// Copyright 2008 Eric Niebler. Distributed under the Boost
-// Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-
-#ifndef BOOST_PP_IS_ITERATING
-#error Do not include this file directly
-#endif
-
-#define M0(Z, N, DATA) \
- typename proto::result_of::as_child<BOOST_PP_CAT(A, N), Domain>::type \
- /**/
-
-#define M1(Z, N, DATA) \
- proto::as_child<Domain>(BOOST_PP_CAT(a, N)) \
- /**/
+#if !defined(BOOST_PROTO_DONT_USE_PREPROCESSED_FILES)
+
+ #include <boost/proto/detail/preprocessed/funop.hpp>
+
+#elif !defined(BOOST_PP_IS_ITERATING)
+
+ #if defined(__WAVE__) && defined(BOOST_PROTO_CREATE_PREPROCESSED_FILES)
+ #pragma wave option(preserve: 2, line: 0, output: "preprocessed/funop.hpp")
+ #endif
+
+ ///////////////////////////////////////////////////////////////////////////////
+ // funop.hpp
+ // Contains definition of funop[n]\<\> class template.
+ //
+ // Copyright 2008 Eric Niebler. Distributed under the Boost
+ // Software License, Version 1.0. (See accompanying file
+ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+ #if defined(__WAVE__) && defined(BOOST_PROTO_CREATE_PREPROCESSED_FILES)
+ #pragma wave option(preserve: 1)
+ #endif
+
+ #define M0(Z, N, DATA) \
+ typename proto::result_of::as_child<BOOST_PP_CAT(A, N), Domain>::type \
+ /**/
+
+ #define M1(Z, N, DATA) \
+ proto::as_child<Domain>(BOOST_PP_CAT(a, N)) \
+ /**/
+
+ #define BOOST_PP_ITERATION_PARAMS_1 \
+ (3, (0, BOOST_PP_DEC(BOOST_PROTO_MAX_FUNCTION_CALL_ARITY), <boost/proto/detail/funop.hpp>))
+ #include BOOST_PP_ITERATE()
+
+ #undef M1
+ #undef M0
+
+ #if defined(__WAVE__) && defined(BOOST_PROTO_CREATE_PREPROCESSED_FILES)
+ #pragma wave option(output: null)
+ #endif
+
+#else
 
     /// \brief A helper metafunction for computing the
     /// return type of \c proto::expr\<\>::operator().
@@ -60,5 +83,4 @@
>
     {};
 
-#undef M0
-#undef M1
+#endif // BOOST_PROTO_DONT_USE_PREPROCESSED_FILES

Added: trunk/boost/proto/detail/preprocessed/basic_expr.hpp
==============================================================================
--- (empty file)
+++ trunk/boost/proto/detail/preprocessed/basic_expr.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -0,0 +1,439 @@
+ ///////////////////////////////////////////////////////////////////////////////
+ /// \file basic_expr.hpp
+ /// Contains definition of basic_expr\<\> class template.
+ //
+ // Copyright 2008 Eric Niebler. Distributed under the Boost
+ // Software License, Version 1.0. (See accompanying file
+ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag, typename Arg0>
+ struct basic_expr<Tag, term<Arg0>, 0>
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 0;
+ typedef mpl::long_<0 > proto_arity;
+ typedef basic_expr proto_base_expr;
+ typedef term<Arg0> proto_args;
+ typedef basic_expr proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef basic_expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0;
+ typedef void proto_child1; typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ basic_expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ basic_expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0>
+ static basic_expr const make(A0 &a0)
+ {
+ return detail::make_terminal(a0, static_cast<basic_expr *>(0), static_cast<proto_args *>(0));
+ }
+
+
+ template<typename A0>
+ static basic_expr const make(A0 const &a0)
+ {
+ return detail::make_terminal(a0, static_cast<basic_expr *>(0), static_cast<proto_args *>(0));
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0>
+ struct basic_expr<Tag, list1<Arg0>, 1 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 1;
+ typedef mpl::long_<1 > proto_arity;
+ typedef basic_expr proto_base_expr;
+ typedef list1<Arg0> proto_args;
+ typedef basic_expr proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef basic_expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0;
+ typedef void proto_child1; typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ basic_expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ basic_expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0>
+ static basic_expr const make(A0 const &a0)
+ {
+ basic_expr that = {a0};
+ return that;
+ }
+
+
+
+ typedef typename detail::address_of_hack<Tag, proto_child0>::type address_of_hack_type_;
+
+
+
+
+
+
+
+ operator address_of_hack_type_() const
+ {
+ return boost::addressof(this->child0);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1>
+ struct basic_expr<Tag, list2<Arg0 , Arg1>, 2 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 2;
+ typedef mpl::long_<2 > proto_arity;
+ typedef basic_expr proto_base_expr;
+ typedef list2<Arg0 , Arg1> proto_args;
+ typedef basic_expr proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef basic_expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1;
+ typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ basic_expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ basic_expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1>
+ static basic_expr const make(A0 const &a0 , A1 const &a1)
+ {
+ basic_expr that = {a0 , a1};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2>
+ struct basic_expr<Tag, list3<Arg0 , Arg1 , Arg2>, 3 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 3;
+ typedef mpl::long_<3 > proto_arity;
+ typedef basic_expr proto_base_expr;
+ typedef list3<Arg0 , Arg1 , Arg2> proto_args;
+ typedef basic_expr proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef basic_expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2;
+ typedef void proto_child3; typedef void proto_child4;
+
+
+ basic_expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ basic_expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2>
+ static basic_expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2)
+ {
+ basic_expr that = {a0 , a1 , a2};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2 , typename Arg3>
+ struct basic_expr<Tag, list4<Arg0 , Arg1 , Arg2 , Arg3>, 4 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 4;
+ typedef mpl::long_<4 > proto_arity;
+ typedef basic_expr proto_base_expr;
+ typedef list4<Arg0 , Arg1 , Arg2 , Arg3> proto_args;
+ typedef basic_expr proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef basic_expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2; typedef Arg3 proto_child3; proto_child3 child3;
+ typedef void proto_child4;
+
+
+ basic_expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ basic_expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ static basic_expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3)
+ {
+ basic_expr that = {a0 , a1 , a2 , a3};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2 , typename Arg3 , typename Arg4>
+ struct basic_expr<Tag, list5<Arg0 , Arg1 , Arg2 , Arg3 , Arg4>, 5 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 5;
+ typedef mpl::long_<5 > proto_arity;
+ typedef basic_expr proto_base_expr;
+ typedef list5<Arg0 , Arg1 , Arg2 , Arg3 , Arg4> proto_args;
+ typedef basic_expr proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef basic_expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2; typedef Arg3 proto_child3; proto_child3 child3; typedef Arg4 proto_child4; proto_child4 child4;
+
+
+
+ basic_expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ basic_expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3 , typename A4>
+ static basic_expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3 , A4 const &a4)
+ {
+ basic_expr that = {a0 , a1 , a2 , a3 , a4};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+ };
+

Added: trunk/boost/proto/detail/preprocessed/expr.hpp
==============================================================================
--- (empty file)
+++ trunk/boost/proto/detail/preprocessed/expr.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -0,0 +1,1538 @@
+ ///////////////////////////////////////////////////////////////////////////////
+ /// \file expr.hpp
+ /// Contains definition of expr\<\> class template.
+ //
+ // Copyright 2008 Eric Niebler. Distributed under the Boost
+ // Software License, Version 1.0. (See accompanying file
+ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag, typename Arg0>
+ struct expr<Tag, term<Arg0>, 0>
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 0;
+ typedef mpl::long_<0 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef term<Arg0> proto_args;
+ typedef basic_expr<Tag, proto_args, 0 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0;
+ typedef void proto_child1; typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0>
+ static expr const make(A0 &a0)
+ {
+ return detail::make_terminal(a0, static_cast<expr *>(0), static_cast<proto_args *>(0));
+ }
+
+
+ template<typename A0>
+ static expr const make(A0 const &a0)
+ {
+ return detail::make_terminal(a0, static_cast<expr *>(0), static_cast<proto_args *>(0));
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a)
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a)
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+
+ proto::expr<proto::tag::function, list1<expr const &>, 1> const
+ operator ()() const
+ {
+ proto::expr<proto::tag::function, list1<expr const &>, 1> that = {*this};
+ return that;
+ }
+
+
+ proto::expr<proto::tag::function, list1<expr &>, 1> const
+ operator ()()
+ {
+ proto::expr<proto::tag::function, list1<expr &>, 1> that = {*this};
+ return that;
+ }
+
+
+ template<typename A0>
+ typename result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::type const
+ operator ()(A0 const &a0) const
+ {
+ return result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::call(*this , a0);
+ }
+
+
+ template<typename A0>
+ typename result_of::funop1<
+ expr
+ , default_domain , const A0
+ >::type const
+ operator ()(A0 const &a0)
+ {
+ return result_of::funop1<
+ expr
+ , default_domain , const A0
+ >::call(*this , a0);
+ }
+
+
+ template<typename A0 , typename A1>
+ typename result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1) const
+ {
+ return result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::call(*this , a0 , a1);
+ }
+
+
+ template<typename A0 , typename A1>
+ typename result_of::funop2<
+ expr
+ , default_domain , const A0 , const A1
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1)
+ {
+ return result_of::funop2<
+ expr
+ , default_domain , const A0 , const A1
+ >::call(*this , a0 , a1);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2>
+ typename result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2) const
+ {
+ return result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::call(*this , a0 , a1 , a2);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2>
+ typename result_of::funop3<
+ expr
+ , default_domain , const A0 , const A1 , const A2
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2)
+ {
+ return result_of::funop3<
+ expr
+ , default_domain , const A0 , const A1 , const A2
+ >::call(*this , a0 , a1 , a2);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ typename result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3) const
+ {
+ return result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::call(*this , a0 , a1 , a2 , a3);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ typename result_of::funop4<
+ expr
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3)
+ {
+ return result_of::funop4<
+ expr
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::call(*this , a0 , a1 , a2 , a3);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0>
+ struct expr<Tag, list1<Arg0>, 1 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 1;
+ typedef mpl::long_<1 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list1<Arg0> proto_args;
+ typedef basic_expr<Tag, proto_args, 1 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0;
+ typedef void proto_child1; typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0>
+ static expr const make(A0 const &a0)
+ {
+ expr that = {a0};
+ return that;
+ }
+
+
+
+ typedef typename detail::address_of_hack<Tag, proto_child0>::type address_of_hack_type_;
+
+
+
+
+
+
+
+ operator address_of_hack_type_() const
+ {
+ return boost::addressof(this->child0);
+ }
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+
+ proto::expr<proto::tag::function, list1<expr const &>, 1> const
+ operator ()() const
+ {
+ proto::expr<proto::tag::function, list1<expr const &>, 1> that = {*this};
+ return that;
+ }
+
+
+ template<typename A0>
+ typename result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::type const
+ operator ()(A0 const &a0) const
+ {
+ return result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::call(*this , a0);
+ }
+
+
+ template<typename A0 , typename A1>
+ typename result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1) const
+ {
+ return result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::call(*this , a0 , a1);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2>
+ typename result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2) const
+ {
+ return result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::call(*this , a0 , a1 , a2);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ typename result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3) const
+ {
+ return result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::call(*this , a0 , a1 , a2 , a3);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1>
+ struct expr<Tag, list2<Arg0 , Arg1>, 2 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 2;
+ typedef mpl::long_<2 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list2<Arg0 , Arg1> proto_args;
+ typedef basic_expr<Tag, proto_args, 2 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1;
+ typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1>
+ static expr const make(A0 const &a0 , A1 const &a1)
+ {
+ expr that = {a0 , a1};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+
+ proto::expr<proto::tag::function, list1<expr const &>, 1> const
+ operator ()() const
+ {
+ proto::expr<proto::tag::function, list1<expr const &>, 1> that = {*this};
+ return that;
+ }
+
+
+ template<typename A0>
+ typename result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::type const
+ operator ()(A0 const &a0) const
+ {
+ return result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::call(*this , a0);
+ }
+
+
+ template<typename A0 , typename A1>
+ typename result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1) const
+ {
+ return result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::call(*this , a0 , a1);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2>
+ typename result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2) const
+ {
+ return result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::call(*this , a0 , a1 , a2);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ typename result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3) const
+ {
+ return result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::call(*this , a0 , a1 , a2 , a3);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2>
+ struct expr<Tag, list3<Arg0 , Arg1 , Arg2>, 3 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 3;
+ typedef mpl::long_<3 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list3<Arg0 , Arg1 , Arg2> proto_args;
+ typedef basic_expr<Tag, proto_args, 3 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2;
+ typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2>
+ static expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2)
+ {
+ expr that = {a0 , a1 , a2};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+
+ proto::expr<proto::tag::function, list1<expr const &>, 1> const
+ operator ()() const
+ {
+ proto::expr<proto::tag::function, list1<expr const &>, 1> that = {*this};
+ return that;
+ }
+
+
+ template<typename A0>
+ typename result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::type const
+ operator ()(A0 const &a0) const
+ {
+ return result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::call(*this , a0);
+ }
+
+
+ template<typename A0 , typename A1>
+ typename result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1) const
+ {
+ return result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::call(*this , a0 , a1);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2>
+ typename result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2) const
+ {
+ return result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::call(*this , a0 , a1 , a2);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ typename result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3) const
+ {
+ return result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::call(*this , a0 , a1 , a2 , a3);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2 , typename Arg3>
+ struct expr<Tag, list4<Arg0 , Arg1 , Arg2 , Arg3>, 4 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 4;
+ typedef mpl::long_<4 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list4<Arg0 , Arg1 , Arg2 , Arg3> proto_args;
+ typedef basic_expr<Tag, proto_args, 4 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2; typedef Arg3 proto_child3; proto_child3 child3;
+ typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ static expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3)
+ {
+ expr that = {a0 , a1 , a2 , a3};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+
+ proto::expr<proto::tag::function, list1<expr const &>, 1> const
+ operator ()() const
+ {
+ proto::expr<proto::tag::function, list1<expr const &>, 1> that = {*this};
+ return that;
+ }
+
+
+ template<typename A0>
+ typename result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::type const
+ operator ()(A0 const &a0) const
+ {
+ return result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::call(*this , a0);
+ }
+
+
+ template<typename A0 , typename A1>
+ typename result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1) const
+ {
+ return result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::call(*this , a0 , a1);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2>
+ typename result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2) const
+ {
+ return result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::call(*this , a0 , a1 , a2);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ typename result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3) const
+ {
+ return result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::call(*this , a0 , a1 , a2 , a3);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2 , typename Arg3 , typename Arg4>
+ struct expr<Tag, list5<Arg0 , Arg1 , Arg2 , Arg3 , Arg4>, 5 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 5;
+ typedef mpl::long_<5 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list5<Arg0 , Arg1 , Arg2 , Arg3 , Arg4> proto_args;
+ typedef basic_expr<Tag, proto_args, 5 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2; typedef Arg3 proto_child3; proto_child3 child3; typedef Arg4 proto_child4; proto_child4 child4;
+
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3 , typename A4>
+ static expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3 , A4 const &a4)
+ {
+ expr that = {a0 , a1 , a2 , a3 , a4};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+
+ proto::expr<proto::tag::function, list1<expr const &>, 1> const
+ operator ()() const
+ {
+ proto::expr<proto::tag::function, list1<expr const &>, 1> that = {*this};
+ return that;
+ }
+
+
+ template<typename A0>
+ typename result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::type const
+ operator ()(A0 const &a0) const
+ {
+ return result_of::funop1<
+ expr const
+ , default_domain , const A0
+ >::call(*this , a0);
+ }
+
+
+ template<typename A0 , typename A1>
+ typename result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1) const
+ {
+ return result_of::funop2<
+ expr const
+ , default_domain , const A0 , const A1
+ >::call(*this , a0 , a1);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2>
+ typename result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2) const
+ {
+ return result_of::funop3<
+ expr const
+ , default_domain , const A0 , const A1 , const A2
+ >::call(*this , a0 , a1 , a2);
+ }
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ typename result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::type const
+ operator ()(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3) const
+ {
+ return result_of::funop4<
+ expr const
+ , default_domain , const A0 , const A1 , const A2 , const A3
+ >::call(*this , a0 , a1 , a2 , a3);
+ }
+ };

Added: trunk/boost/proto/detail/preprocessed/expr_variadic.hpp
==============================================================================
--- (empty file)
+++ trunk/boost/proto/detail/preprocessed/expr_variadic.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -0,0 +1,1201 @@
+ ///////////////////////////////////////////////////////////////////////////////
+ /// \file expr_variadic.hpp
+ /// Contains definition of expr\<\> class template.
+ //
+ // Copyright 2008 Eric Niebler. Distributed under the Boost
+ // Software License, Version 1.0. (See accompanying file
+ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag, typename Arg0>
+ struct expr<Tag, term<Arg0>, 0>
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 0;
+ typedef mpl::long_<0 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef term<Arg0> proto_args;
+ typedef basic_expr<Tag, proto_args, 0 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0;
+ typedef void proto_child1; typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0>
+ static expr const make(A0 &a0)
+ {
+ return detail::make_terminal(a0, static_cast<expr *>(0), static_cast<proto_args *>(0));
+ }
+
+
+ template<typename A0>
+ static expr const make(A0 const &a0)
+ {
+ return detail::make_terminal(a0, static_cast<expr *>(0), static_cast<proto_args *>(0));
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a)
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a)
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+ template<typename ...A>
+ typename result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::type const
+ operator ()(A const &... a) const
+ {
+ return result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::call(*this, a...);
+ }
+
+
+ template<typename ...A>
+ typename result_of::funop<
+ expr(A const &...)
+ , expr
+ , default_domain
+ >::type const
+ operator ()(A const &... a)
+ {
+ return result_of::funop<
+ expr(A const &...)
+ , expr
+ , default_domain
+ >::call(*this, a...);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0>
+ struct expr<Tag, list1<Arg0>, 1 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 1;
+ typedef mpl::long_<1 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list1<Arg0> proto_args;
+ typedef basic_expr<Tag, proto_args, 1 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0;
+ typedef void proto_child1; typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0>
+ static expr const make(A0 const &a0)
+ {
+ expr that = {a0};
+ return that;
+ }
+
+
+
+ typedef typename detail::address_of_hack<Tag, proto_child0>::type address_of_hack_type_;
+
+
+
+
+
+
+
+ operator address_of_hack_type_() const
+ {
+ return boost::addressof(this->child0);
+ }
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+ template<typename ...A>
+ typename result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::type const
+ operator ()(A const &... a) const
+ {
+ return result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::call(*this, a...);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1>
+ struct expr<Tag, list2<Arg0 , Arg1>, 2 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 2;
+ typedef mpl::long_<2 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list2<Arg0 , Arg1> proto_args;
+ typedef basic_expr<Tag, proto_args, 2 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1;
+ typedef void proto_child2; typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1>
+ static expr const make(A0 const &a0 , A1 const &a1)
+ {
+ expr that = {a0 , a1};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+ template<typename ...A>
+ typename result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::type const
+ operator ()(A const &... a) const
+ {
+ return result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::call(*this, a...);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2>
+ struct expr<Tag, list3<Arg0 , Arg1 , Arg2>, 3 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 3;
+ typedef mpl::long_<3 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list3<Arg0 , Arg1 , Arg2> proto_args;
+ typedef basic_expr<Tag, proto_args, 3 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2;
+ typedef void proto_child3; typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2>
+ static expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2)
+ {
+ expr that = {a0 , a1 , a2};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+ template<typename ...A>
+ typename result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::type const
+ operator ()(A const &... a) const
+ {
+ return result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::call(*this, a...);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2 , typename Arg3>
+ struct expr<Tag, list4<Arg0 , Arg1 , Arg2 , Arg3>, 4 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 4;
+ typedef mpl::long_<4 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list4<Arg0 , Arg1 , Arg2 , Arg3> proto_args;
+ typedef basic_expr<Tag, proto_args, 4 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2; typedef Arg3 proto_child3; proto_child3 child3;
+ typedef void proto_child4;
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3>
+ static expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3)
+ {
+ expr that = {a0 , a1 , a2 , a3};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+ template<typename ...A>
+ typename result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::type const
+ operator ()(A const &... a) const
+ {
+ return result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::call(*this, a...);
+ }
+ };
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ template<typename Tag , typename Arg0 , typename Arg1 , typename Arg2 , typename Arg3 , typename Arg4>
+ struct expr<Tag, list5<Arg0 , Arg1 , Arg2 , Arg3 , Arg4>, 5 >
+ {
+ typedef Tag proto_tag;
+ static const long proto_arity_c = 5;
+ typedef mpl::long_<5 > proto_arity;
+ typedef expr proto_base_expr;
+ typedef list5<Arg0 , Arg1 , Arg2 , Arg3 , Arg4> proto_args;
+ typedef basic_expr<Tag, proto_args, 5 > proto_grammar;
+ typedef default_domain proto_domain;
+ typedef default_generator proto_generator;
+ typedef proto::tag::proto_expr fusion_tag;
+ typedef expr proto_derived_expr;
+ typedef void proto_is_expr_;
+ typedef Arg0 proto_child0; proto_child0 child0; typedef Arg1 proto_child1; proto_child1 child1; typedef Arg2 proto_child2; proto_child2 child2; typedef Arg3 proto_child3; proto_child3 child3; typedef Arg4 proto_child4; proto_child4 child4;
+
+
+
+ expr const &proto_base() const
+ {
+ return *this;
+ }
+
+
+ expr &proto_base()
+ {
+ return *this;
+ }
+
+
+
+ template<typename A0 , typename A1 , typename A2 , typename A3 , typename A4>
+ static expr const make(A0 const &a0 , A1 const &a1 , A2 const &a2 , A3 const &a3 , A4 const &a4)
+ {
+ expr that = {a0 , a1 , a2 , a3 , a4};
+ return that;
+ }
+
+
+ typedef detail::not_a_valid_type address_of_hack_type_;
+
+
+
+
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > const
+ operator =(expr const &a)
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr &, expr const &>
+ , 2
+ > that = {*this, a};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator =(A &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator =(A const &a) const
+ {
+ proto::expr<
+ proto::tag::assign
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > const
+ operator [](A &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename A>
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > const
+ operator [](A const &a) const
+ {
+ proto::expr<
+ proto::tag::subscript
+ , list2<expr const &, typename result_of::as_child<A const>::type>
+ , 2
+ > that = {*this, proto::as_child(a)};
+ return that;
+ }
+
+
+ template<typename Sig>
+ struct result
+ {
+ typedef typename result_of::funop<Sig, expr, default_domain>::type const type;
+ };
+
+
+ template<typename ...A>
+ typename result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::type const
+ operator ()(A const &... a) const
+ {
+ return result_of::funop<
+ expr const(A const &...)
+ , expr
+ , default_domain
+ >::call(*this, a...);
+ }
+ };
+

Added: trunk/boost/proto/detail/preprocessed/funop.hpp
==============================================================================
--- (empty file)
+++ trunk/boost/proto/detail/preprocessed/funop.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -0,0 +1,182 @@
+ ///////////////////////////////////////////////////////////////////////////////
+ // funop.hpp
+ // Contains definition of funop[n]\<\> class template.
+ //
+ // Copyright 2008 Eric Niebler. Distributed under the Boost
+ // Software License, Version 1.0. (See accompanying file
+ // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+
+ template<typename Expr, typename Domain >
+ struct funop0
+ {
+ typedef typename proto::base_expr<
+ Domain
+ , tag::function
+ , list1<
+ Expr &
+
+ >
+ >::type type;
+ static type const call(
+ Expr &e
+
+ )
+ {
+ type that = {
+ e
+
+ };
+ return that;
+ }
+ };
+
+
+ template<typename Expr , typename This, typename Domain>
+ struct funop<Expr(), This, Domain>
+ : funop0<
+ typename detail::same_cv<Expr, This>::type
+ , Domain
+
+ >
+ {};
+
+
+ template<typename Expr, typename Domain , typename A0>
+ struct funop1
+ {
+ typedef typename proto::base_expr<
+ Domain
+ , tag::function
+ , list2<
+ Expr &
+ , typename proto::result_of::as_child<A0, Domain>::type
+ >
+ >::type type;
+ static type const call(
+ Expr &e
+ , A0 &a0
+ )
+ {
+ type that = {
+ e
+ , proto::as_child<Domain>(a0)
+ };
+ return that;
+ }
+ };
+
+
+ template<typename Expr , typename A0, typename This, typename Domain>
+ struct funop<Expr(A0), This, Domain>
+ : funop1<
+ typename detail::same_cv<Expr, This>::type
+ , Domain
+ , typename remove_reference<A0 >::type
+ >
+ {};
+
+
+ template<typename Expr, typename Domain , typename A0 , typename A1>
+ struct funop2
+ {
+ typedef typename proto::base_expr<
+ Domain
+ , tag::function
+ , list3<
+ Expr &
+ , typename proto::result_of::as_child<A0, Domain>::type , typename proto::result_of::as_child<A1, Domain>::type
+ >
+ >::type type;
+ static type const call(
+ Expr &e
+ , A0 &a0 , A1 &a1
+ )
+ {
+ type that = {
+ e
+ , proto::as_child<Domain>(a0) , proto::as_child<Domain>(a1)
+ };
+ return that;
+ }
+ };
+
+
+ template<typename Expr , typename A0 , typename A1, typename This, typename Domain>
+ struct funop<Expr(A0 , A1), This, Domain>
+ : funop2<
+ typename detail::same_cv<Expr, This>::type
+ , Domain
+ , typename remove_reference<A0 >::type , typename remove_reference<A1 >::type
+ >
+ {};
+
+
+ template<typename Expr, typename Domain , typename A0 , typename A1 , typename A2>
+ struct funop3
+ {
+ typedef typename proto::base_expr<
+ Domain
+ , tag::function
+ , list4<
+ Expr &
+ , typename proto::result_of::as_child<A0, Domain>::type , typename proto::result_of::as_child<A1, Domain>::type , typename proto::result_of::as_child<A2, Domain>::type
+ >
+ >::type type;
+ static type const call(
+ Expr &e
+ , A0 &a0 , A1 &a1 , A2 &a2
+ )
+ {
+ type that = {
+ e
+ , proto::as_child<Domain>(a0) , proto::as_child<Domain>(a1) , proto::as_child<Domain>(a2)
+ };
+ return that;
+ }
+ };
+
+
+ template<typename Expr , typename A0 , typename A1 , typename A2, typename This, typename Domain>
+ struct funop<Expr(A0 , A1 , A2), This, Domain>
+ : funop3<
+ typename detail::same_cv<Expr, This>::type
+ , Domain
+ , typename remove_reference<A0 >::type , typename remove_reference<A1 >::type , typename remove_reference<A2 >::type
+ >
+ {};
+
+
+ template<typename Expr, typename Domain , typename A0 , typename A1 , typename A2 , typename A3>
+ struct funop4
+ {
+ typedef typename proto::base_expr<
+ Domain
+ , tag::function
+ , list5<
+ Expr &
+ , typename proto::result_of::as_child<A0, Domain>::type , typename proto::result_of::as_child<A1, Domain>::type , typename proto::result_of::as_child<A2, Domain>::type , typename proto::result_of::as_child<A3, Domain>::type
+ >
+ >::type type;
+ static type const call(
+ Expr &e
+ , A0 &a0 , A1 &a1 , A2 &a2 , A3 &a3
+ )
+ {
+ type that = {
+ e
+ , proto::as_child<Domain>(a0) , proto::as_child<Domain>(a1) , proto::as_child<Domain>(a2) , proto::as_child<Domain>(a3)
+ };
+ return that;
+ }
+ };
+
+
+ template<typename Expr , typename A0 , typename A1 , typename A2 , typename A3, typename This, typename Domain>
+ struct funop<Expr(A0 , A1 , A2 , A3), This, Domain>
+ : funop4<
+ typename detail::same_cv<Expr, This>::type
+ , Domain
+ , typename remove_reference<A0 >::type , typename remove_reference<A1 >::type , typename remove_reference<A2 >::type , typename remove_reference<A3 >::type
+ >
+ {};

Modified: trunk/boost/proto/expr.hpp
==============================================================================
--- trunk/boost/proto/expr.hpp (original)
+++ trunk/boost/proto/expr.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -37,19 +37,6 @@
 
     namespace detail
     {
- /// INTERNAL ONLY
- ///
- #define BOOST_PROTO_CHILD(Z, N, DATA) \
- typedef BOOST_PP_CAT(Arg, N) BOOST_PP_CAT(proto_child, N); \
- BOOST_PP_CAT(proto_child, N) BOOST_PP_CAT(child, N); \
- /**< INTERNAL ONLY */
-
- /// INTERNAL ONLY
- ///
- #define BOOST_PROTO_VOID(Z, N, DATA) \
- typedef void BOOST_PP_CAT(proto_child, N); \
- /**< INTERNAL ONLY */
-
         struct not_a_valid_type
         {
         private:
@@ -118,25 +105,20 @@
         template<typename Sig, typename This, typename Domain>
         struct funop;
 
- #define BOOST_PP_ITERATION_PARAMS_1 (3, (0, BOOST_PP_DEC(BOOST_PROTO_MAX_FUNCTION_CALL_ARITY), <boost/proto/detail/funop.hpp>))
- #include BOOST_PP_ITERATE()
+ #include <boost/proto/detail/funop.hpp>
     }
 
     namespace exprns_
     {
- // The expr<> specializations are actually defined here.
- #define BOOST_PROTO_DEFINE_TERMINAL
- #define BOOST_PP_ITERATION_PARAMS_1 (3, (0, 0, <boost/proto/detail/expr0.hpp>))
- #include BOOST_PP_ITERATE()
-
- #undef BOOST_PROTO_DEFINE_TERMINAL
- #define BOOST_PP_ITERATION_PARAMS_1 (3, (1, BOOST_PROTO_MAX_ARITY, <boost/proto/detail/expr0.hpp>))
- #include BOOST_PP_ITERATE()
+ // This is where the basic_expr specializations are
+ // actually defined:
+ #include <boost/proto/detail/basic_expr.hpp>
+
+ // This is where the expr specialization are
+ // actually defined:
+ #include <boost/proto/detail/expr.hpp>
     }
 
- #undef BOOST_PROTO_CHILD
- #undef BOOST_PROTO_VOID
-
     /// \brief Lets you inherit the interface of an expression
     /// while hiding from Proto the fact that the type is a Proto
     /// expression.

Modified: trunk/boost/proto/proto_fwd.hpp
==============================================================================
--- trunk/boost/proto/proto_fwd.hpp (original)
+++ trunk/boost/proto/proto_fwd.hpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -45,6 +45,14 @@
 # error BOOST_PROTO_MAX_FUNCTION_CALL_ARITY cannot be larger than BOOST_PROTO_MAX_ARITY
 #endif
 
+#ifndef BOOST_PROTO_DONT_USE_PREPROCESSED_FILES
+ #if 5 != BOOST_PROTO_MAX_ARITY || \
+ 8 != BOOST_PROTO_MAX_LOGICAL_ARITY || \
+ 5 != BOOST_PROTO_MAX_FUNCTION_CALL_ARITY
+ #define BOOST_PROTO_DONT_USE_PREPROCESSED_FILES
+ #endif
+#endif
+
 #ifndef BOOST_PROTO_BROKEN_CONST_OVERLOADS
 # if BOOST_WORKAROUND(__GNUC__, == 3) \
   || BOOST_WORKAROUND(__EDG_VERSION__, BOOST_TESTED_AT(310))

Added: trunk/libs/proto/preprocess/preprocess_proto.cpp
==============================================================================
--- (empty file)
+++ trunk/libs/proto/preprocess/preprocess_proto.cpp 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -0,0 +1,12 @@
+///////////////////////////////////////////////////////////////////////////////
+// Copyright 2011 Eric Niebler. Distributed under the Boost
+// Software License, Version 1.0. (See accompanying file
+// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+//#include <boost/proto/core.hpp>
+//#include <boost/proto/debug.hpp>
+//#include <boost/proto/context.hpp>
+//#include <boost/proto/transform.hpp>
+//#include <boost/proto/functional.hpp>
+
+#include <boost/proto/expr.hpp>

Added: trunk/libs/proto/preprocess/wave.cfg
==============================================================================
--- (empty file)
+++ trunk/libs/proto/preprocess/wave.cfg 2011-05-05 05:41:11 EDT (Thu, 05 May 2011)
@@ -0,0 +1,7 @@
+-DBOOST_PROTO_DONT_USE_PREPROCESSED_FILES
+-DBOOST_PROTO_CREATE_PREPROCESSED_FILES
+-D_WIN32
+-SC:\boost\org\trunk
+-S"C:\Program Files\Microsoft Visual Studio 10.0\VC\include"
+-S.
+--variadics


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk