Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r74935 - in branches/release: . boost boost/algorithm/string boost/archive boost/bimap boost/config boost/date_time boost/date_time/posix_time boost/detail boost/dynamic_bitset boost/filesystem boost/function boost/functional boost/fusion boost/geometry boost/geometry/algorithms boost/geometry/arithmetic boost/geometry/core boost/geometry/domains boost/geometry/geometries boost/geometry/iterators boost/geometry/multi boost/geometry/policies boost/geometry/strategies boost/geometry/util boost/geometry/views boost/gil boost/graph boost/icl boost/integer boost/interprocess boost/intrusive boost/io boost/iostreams boost/iterator boost/locale boost/math boost/msm boost/msm/back boost/msm/front boost/msm/front/detail boost/msm/front/euml boost/numeric/ublas boost/pool boost/program_options boost/program_options/detail boost/property_tree boost/proto boost/proto/transform boost/range boost/regex boost/serialization boost/signals boost/signals2 boost/spirit boost/spirit/home boost/spirit/home/karma boost/spirit/home/support boost/statechart boost/system boost/thread boost/tr1 boost/typeof boost/utility boost/uuid boost/variant boost/wave boost/xpressive doc libs libs/algorithm/string libs/array libs/array/test libs/bimap libs/config libs/date_time libs/date_time/data libs/date_time/example/gregorian libs/date_time/example/local_time libs/date_time/example/posix_time libs/date_time/example/tutorial libs/date_time/test/posix_time libs/date_time/xmldoc libs/detail libs/filesystem libs/function libs/functional libs/fusion libs/geometry libs/geometry/doc libs/geometry/doc/concept libs/geometry/doc/doxy libs/geometry/doc/generated libs/geometry/doc/html libs/geometry/doc/reference libs/geometry/doc/src libs/geometry/example libs/geometry/test libs/graph/doc libs/graph_parallel libs/icl libs/icl/doc libs/icl/doc/html libs/icl/doc/html/header/boost/icl libs/icl/test libs/icl/test/test_doc_code_ libs/integer libs/interprocess libs/intrusive libs/io libs/io/doc libs/iostreams libs/iterator libs/locale libs/math libs/math/doc/sf_and_dist libs/math/doc/sf_and_dist/html/math_toolkit/main_overview libs/math/test libs/mpi/build libs/mpl/doc/refmanual libs/mpl/doc/src/refmanual libs/msm libs/numeric/ublas libs/numeric/ublas/doc libs/parameter/doc/html libs/phoenix/doc libs/phoenix/doc/examples libs/pool libs/program_options libs/program_options/test libs/property_tree libs/proto/test libs/range libs/regex libs/serialization libs/serialization/example libs/serialization/src libs/serialization/test libs/signals libs/signals2 libs/signals2/doc libs/spirit libs/spirit/classic/example libs/spirit/doc libs/spirit/example libs/spirit/phoenix libs/spirit/test libs/spirit/test/qi libs/statechart libs/static_assert libs/system libs/thread libs/timer libs/tr1 libs/typeof/doc libs/utility libs/utility/swap/test libs/uuid libs/wave more status tools tools/bcp tools/boostbook tools/build/v2 tools/build/v2/tools tools/inspect tools/quickbook tools/regression tools/regression/src tools/release tools/wave
From: eric_at_[hidden]
Date: 2011-10-13 02:33:13


Author: eric_niebler
Date: 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
New Revision: 74935
URL: http://svn.boost.org/trac/boost/changeset/74935

Log:
merged [74909] [74919] [74923] from trunk
Properties modified:
   branches/release/ (props changed)
   branches/release/INSTALL (props changed)
   branches/release/Jamroot (props changed)
   branches/release/LICENSE_1_0.txt (props changed)
   branches/release/boost/ (props changed)
   branches/release/boost-build.jam (props changed)
   branches/release/boost.css (props changed)
   branches/release/boost.png (props changed)
   branches/release/boost/algorithm/string/ (props changed)
   branches/release/boost/archive/ (props changed)
   branches/release/boost/array.hpp (props changed)
   branches/release/boost/bimap/ (props changed)
   branches/release/boost/concept_check.hpp (props changed)
   branches/release/boost/config/ (props changed)
   branches/release/boost/config.hpp (props changed)
   branches/release/boost/cregex.hpp (props changed)
   branches/release/boost/cstdint.hpp (props changed)
   branches/release/boost/current_function.hpp (props changed)
   branches/release/boost/date_time/c_time.hpp (props changed)
   branches/release/boost/date_time/date_formatting.hpp (props changed)
   branches/release/boost/date_time/filetime_functions.hpp (props changed)
   branches/release/boost/date_time/gregorian_calendar.ipp (props changed)
   branches/release/boost/date_time/posix_time/time_serialize.hpp (props changed)
   branches/release/boost/date_time/strings_from_facet.hpp (props changed)
   branches/release/boost/date_time/time_facet.hpp (props changed)
   branches/release/boost/date_time/tz_db_base.hpp (props changed)
   branches/release/boost/detail/ (props changed)
   branches/release/boost/detail/interlocked.hpp (props changed)
   branches/release/boost/dynamic_bitset/dynamic_bitset.hpp (props changed)
   branches/release/boost/filesystem/ (props changed)
   branches/release/boost/filesystem.hpp (props changed)
   branches/release/boost/function/ (props changed)
   branches/release/boost/function/function_template.hpp (props changed)
   branches/release/boost/functional/ (props changed)
   branches/release/boost/fusion/ (props changed)
   branches/release/boost/geometry/ (props changed)
   branches/release/boost/geometry/algorithms/ (props changed)
   branches/release/boost/geometry/arithmetic/ (props changed)
   branches/release/boost/geometry/core/ (props changed)
   branches/release/boost/geometry/domains/ (props changed)
   branches/release/boost/geometry/geometries/ (props changed)
   branches/release/boost/geometry/geometry.hpp (props changed)
   branches/release/boost/geometry/iterators/ (props changed)
   branches/release/boost/geometry/multi/ (props changed)
   branches/release/boost/geometry/policies/ (props changed)
   branches/release/boost/geometry/strategies/ (props changed)
   branches/release/boost/geometry/util/ (props changed)
   branches/release/boost/geometry/views/ (props changed)
   branches/release/boost/gil/ (props changed)
   branches/release/boost/graph/ (props changed)
   branches/release/boost/icl/ (props changed)
   branches/release/boost/integer/ (props changed)
   branches/release/boost/integer.hpp (props changed)
   branches/release/boost/integer_fwd.hpp (props changed)
   branches/release/boost/integer_traits.hpp (props changed)
   branches/release/boost/interprocess/ (props changed)
   branches/release/boost/intrusive/ (props changed)
   branches/release/boost/io/ (props changed)
   branches/release/boost/iostreams/ (props changed)
   branches/release/boost/iterator/ (props changed)
   branches/release/boost/iterator/iterator_facade.hpp (props changed)
   branches/release/boost/locale/ (props changed)
   branches/release/boost/locale.hpp (props changed)
   branches/release/boost/math/ (props changed)
   branches/release/boost/math_fwd.hpp (props changed)
   branches/release/boost/msm/ (props changed)
   branches/release/boost/msm/active_state_switching_policies.hpp (props changed)
   branches/release/boost/msm/back/ (props changed)
   branches/release/boost/msm/back/args.hpp (props changed)
   branches/release/boost/msm/back/bind_helpers.hpp (props changed)
   branches/release/boost/msm/back/common_types.hpp (props changed)
   branches/release/boost/msm/back/copy_policies.hpp (props changed)
   branches/release/boost/msm/back/default_compile_policy.hpp (props changed)
   branches/release/boost/msm/back/dispatch_table.hpp (props changed)
   branches/release/boost/msm/back/favor_compile_time.hpp (props changed)
   branches/release/boost/msm/back/fold_to_list.hpp (props changed)
   branches/release/boost/msm/back/history_policies.hpp (props changed)
   branches/release/boost/msm/back/metafunctions.hpp (props changed)
   branches/release/boost/msm/back/mpl_graph_fsm_check.hpp (props changed)
   branches/release/boost/msm/back/no_fsm_check.hpp (props changed)
   branches/release/boost/msm/back/queue_container_circular.hpp (props changed)
   branches/release/boost/msm/back/queue_container_deque.hpp (props changed)
   branches/release/boost/msm/back/state_machine.hpp (props changed)
   branches/release/boost/msm/back/tools.hpp (props changed)
   branches/release/boost/msm/common.hpp (props changed)
   branches/release/boost/msm/front/ (props changed)
   branches/release/boost/msm/front/common_states.hpp (props changed)
   branches/release/boost/msm/front/completion_event.hpp (props changed)
   branches/release/boost/msm/front/detail/ (props changed)
   branches/release/boost/msm/front/detail/common_states.hpp (props changed)
   branches/release/boost/msm/front/detail/row2_helper.hpp (props changed)
   branches/release/boost/msm/front/euml/ (props changed)
   branches/release/boost/msm/front/euml/algorithm.hpp (props changed)
   branches/release/boost/msm/front/euml/common.hpp (props changed)
   branches/release/boost/msm/front/euml/container.hpp (props changed)
   branches/release/boost/msm/front/euml/euml.hpp (props changed)
   branches/release/boost/msm/front/euml/euml_typeof.hpp (props changed)
   branches/release/boost/msm/front/euml/guard_grammar.hpp (props changed)
   branches/release/boost/msm/front/euml/iteration.hpp (props changed)
   branches/release/boost/msm/front/euml/operator.hpp (props changed)
   branches/release/boost/msm/front/euml/phoenix_placeholders.hpp (props changed)
   branches/release/boost/msm/front/euml/querying.hpp (props changed)
   branches/release/boost/msm/front/euml/state_grammar.hpp (props changed)
   branches/release/boost/msm/front/euml/stl.hpp (props changed)
   branches/release/boost/msm/front/euml/stt_grammar.hpp (props changed)
   branches/release/boost/msm/front/euml/transformation.hpp (props changed)
   branches/release/boost/msm/front/functor_row.hpp (props changed)
   branches/release/boost/msm/front/internal_row.hpp (props changed)
   branches/release/boost/msm/front/row2.hpp (props changed)
   branches/release/boost/msm/front/state_machine_def.hpp (props changed)
   branches/release/boost/msm/front/states.hpp (props changed)
   branches/release/boost/msm/msm_grammar.hpp (props changed)
   branches/release/boost/msm/proto_config.hpp (props changed)
   branches/release/boost/msm/row_tags.hpp (props changed)
   branches/release/boost/numeric/ublas/ (props changed)
   branches/release/boost/numeric/ublas/functional.hpp (props changed)
   branches/release/boost/pool/ (props changed)
   branches/release/boost/program_options/ (props changed)
   branches/release/boost/program_options/detail/parsers.hpp (props changed)
   branches/release/boost/program_options/parsers.hpp (props changed)
   branches/release/boost/property_tree/ (props changed)
   branches/release/boost/range/ (props changed)
   branches/release/boost/regex/ (props changed)
   branches/release/boost/regex.h (props changed)
   branches/release/boost/regex.hpp (props changed)
   branches/release/boost/regex_fwd.hpp (props changed)
   branches/release/boost/serialization/ (props changed)
   branches/release/boost/signals/ (props changed)
   branches/release/boost/signals2/ (props changed)
   branches/release/boost/signals2.hpp (props changed)
   branches/release/boost/spirit/ (props changed)
   branches/release/boost/spirit/home/ (props changed)
   branches/release/boost/spirit/home/karma/ (props changed)
   branches/release/boost/spirit/home/support/attributes.hpp (props changed)
   branches/release/boost/statechart/ (props changed)
   branches/release/boost/static_assert.hpp (props changed)
   branches/release/boost/system/ (props changed)
   branches/release/boost/thread/ (props changed)
   branches/release/boost/thread.hpp (props changed)
   branches/release/boost/timer.hpp (props changed)
   branches/release/boost/token_functions.hpp (props changed)
   branches/release/boost/tr1/ (props changed)
   branches/release/boost/typeof/message.hpp (props changed)
   branches/release/boost/typeof/register_functions.hpp (props changed)
   branches/release/boost/typeof/register_functions_iterate.hpp (props changed)
   branches/release/boost/typeof/typeof.hpp (props changed)
   branches/release/boost/typeof/unsupported.hpp (props changed)
   branches/release/boost/utility/ (props changed)
   branches/release/boost/utility/value_init.hpp (props changed)
   branches/release/boost/uuid/ (props changed)
   branches/release/boost/variant/ (props changed)
   branches/release/boost/version.hpp (props changed)
   branches/release/boost/wave/ (props changed)
   branches/release/boost/xpressive/ (props changed)
   branches/release/boostcpp.jam (props changed)
   branches/release/bootstrap.bat (props changed)
   branches/release/bootstrap.sh (props changed)
   branches/release/doc/ (props changed)
   branches/release/index.htm (props changed)
   branches/release/index.html (props changed)
   branches/release/libs/ (props changed)
   branches/release/libs/algorithm/string/ (props changed)
   branches/release/libs/array/ (props changed)
   branches/release/libs/array/test/array0.cpp (props changed)
   branches/release/libs/array/test/array2.cpp (props changed)
   branches/release/libs/array/test/array6.cpp (props changed)
   branches/release/libs/bimap/ (props changed)
   branches/release/libs/config/ (props changed)
   branches/release/libs/date_time/ (props changed)
   branches/release/libs/date_time/data/date_time_zonespec.csv (props changed)
   branches/release/libs/date_time/example/gregorian/days_between_new_years.cpp (props changed)
   branches/release/libs/date_time/example/gregorian/days_since_year_start.cpp (props changed)
   branches/release/libs/date_time/example/gregorian/days_till_new_year.cpp (props changed)
   branches/release/libs/date_time/example/gregorian/month_add.cpp (props changed)
   branches/release/libs/date_time/example/local_time/flight.cpp (props changed)
   branches/release/libs/date_time/example/local_time/local_date_time.cpp (props changed)
   branches/release/libs/date_time/example/posix_time/print_hours.cpp (props changed)
   branches/release/libs/date_time/example/posix_time/time_math.cpp (props changed)
   branches/release/libs/date_time/example/tutorial/io_tutorial.cpp (props changed)
   branches/release/libs/date_time/test/posix_time/testtime_facet.cpp (props changed)
   branches/release/libs/date_time/test/posix_time/testtime_input_facet.cpp (props changed)
   branches/release/libs/date_time/xmldoc/date_class.xml (props changed)
   branches/release/libs/date_time/xmldoc/usage_examples.xml (props changed)
   branches/release/libs/detail/ (props changed)
   branches/release/libs/filesystem/ (props changed)
   branches/release/libs/function/ (props changed)
   branches/release/libs/functional/ (props changed)
   branches/release/libs/fusion/ (props changed)
   branches/release/libs/geometry/ (props changed)
   branches/release/libs/geometry/doc/ (props changed)
   branches/release/libs/geometry/doc/Jamfile.v2 (props changed)
   branches/release/libs/geometry/doc/about_documentation.qbk (props changed)
   branches/release/libs/geometry/doc/acknowledgments.qbk (props changed)
   branches/release/libs/geometry/doc/concept/ (props changed)
   branches/release/libs/geometry/doc/copyright_note_policy.txt (props changed)
   branches/release/libs/geometry/doc/design_rationale.qbk (props changed)
   branches/release/libs/geometry/doc/doxy/ (props changed)
   branches/release/libs/geometry/doc/generated/ (props changed)
   branches/release/libs/geometry/doc/geometry.qbk (props changed)
   branches/release/libs/geometry/doc/html/ (props changed)
   branches/release/libs/geometry/doc/imports.qbk (props changed)
   branches/release/libs/geometry/doc/introduction.qbk (props changed)
   branches/release/libs/geometry/doc/make_qbk.py (props changed)
   branches/release/libs/geometry/doc/matrix.qbk (props changed)
   branches/release/libs/geometry/doc/quickref.xml (props changed)
   branches/release/libs/geometry/doc/quickstart.qbk (props changed)
   branches/release/libs/geometry/doc/readme.txt (props changed)
   branches/release/libs/geometry/doc/reference/ (props changed)
   branches/release/libs/geometry/doc/reference.qbk (props changed)
   branches/release/libs/geometry/doc/src/ (props changed)
   branches/release/libs/geometry/example/ (props changed)
   branches/release/libs/geometry/index.html (props changed)
   branches/release/libs/geometry/test/ (props changed)
   branches/release/libs/graph/doc/ (props changed)
   branches/release/libs/graph_parallel/ (props changed)
   branches/release/libs/icl/ (props changed)
   branches/release/libs/icl/doc/ (props changed)
   branches/release/libs/icl/doc/html/ (props changed)
   branches/release/libs/icl/doc/html/header/boost/icl/ (props changed)
   branches/release/libs/icl/test/ (props changed)
   branches/release/libs/icl/test/test_doc_code_/ (props changed)
   branches/release/libs/integer/ (props changed)
   branches/release/libs/interprocess/ (props changed)
   branches/release/libs/intrusive/ (props changed)
   branches/release/libs/io/ (props changed)
   branches/release/libs/io/doc/ (props changed)
   branches/release/libs/iostreams/ (props changed)
   branches/release/libs/iterator/ (props changed)
   branches/release/libs/libraries.htm (props changed)
   branches/release/libs/locale/ (props changed)
   branches/release/libs/maintainers.txt (props changed)
   branches/release/libs/math/ (props changed)
   branches/release/libs/math/doc/sf_and_dist/faq.qbk (props changed)
   branches/release/libs/math/doc/sf_and_dist/html/math_toolkit/main_overview/faq.html (props changed)
   branches/release/libs/math/test/s_.ipp (props changed)
   branches/release/libs/mpi/build/ (props changed)
   branches/release/libs/mpl/doc/refmanual/broken-compiler-workarounds.html (props changed)
   branches/release/libs/mpl/doc/refmanual/categorized-index-concepts.html (props changed)
   branches/release/libs/mpl/doc/refmanual/cfg-no-preprocessed-headers.html (props changed)
   branches/release/libs/mpl/doc/refmanual/composition-and-argument-binding.html (props changed)
   branches/release/libs/mpl/doc/refmanual/data-types-concepts.html (props changed)
   branches/release/libs/mpl/doc/refmanual/data-types-miscellaneous.html (props changed)
   branches/release/libs/mpl/doc/refmanual/extensible-associative-sequence.html (props changed)
   branches/release/libs/mpl/doc/refmanual/inserter-class.html (props changed)
   branches/release/libs/mpl/doc/refmanual/tag-dispatched-metafunction.html (props changed)
   branches/release/libs/mpl/doc/refmanual/trivial-metafunctions-summary.html (props changed)
   branches/release/libs/mpl/doc/src/refmanual/Iterators-Iterator.rst (props changed)
   branches/release/libs/msm/ (props changed)
   branches/release/libs/numeric/ublas/ (props changed)
   branches/release/libs/numeric/ublas/doc/ (props changed)
   branches/release/libs/parameter/doc/html/index.html (props changed)
   branches/release/libs/phoenix/doc/basics.qbk (props changed)
   branches/release/libs/phoenix/doc/examples/extending_actors.qbk (props changed)
   branches/release/libs/phoenix/doc/organisation.qbk (props changed)
   branches/release/libs/pool/ (props changed)
   branches/release/libs/program_options/ (props changed)
   branches/release/libs/program_options/test/parsers_test.cpp (props changed)
   branches/release/libs/property_tree/ (props changed)
   branches/release/libs/range/ (props changed)
   branches/release/libs/regex/ (props changed)
   branches/release/libs/serialization/ (props changed)
   branches/release/libs/serialization/example/ (props changed)
   branches/release/libs/serialization/src/ (props changed)
   branches/release/libs/serialization/test/test_diamond_complex.cpp (props changed)
   branches/release/libs/signals/ (props changed)
   branches/release/libs/signals2/ (props changed)
   branches/release/libs/signals2/doc/ (props changed)
   branches/release/libs/spirit/ (props changed)
   branches/release/libs/spirit/classic/example/ (props changed)
   branches/release/libs/spirit/doc/ (props changed)
   branches/release/libs/spirit/example/ (props changed)
   branches/release/libs/spirit/phoenix/ (props changed)
   branches/release/libs/spirit/test/ (props changed)
   branches/release/libs/spirit/test/qi/optional.cpp (props changed)
   branches/release/libs/statechart/ (props changed)
   branches/release/libs/static_assert/ (props changed)
   branches/release/libs/system/ (props changed)
   branches/release/libs/thread/ (props changed)
   branches/release/libs/timer/ (props changed)
   branches/release/libs/tr1/ (props changed)
   branches/release/libs/typeof/doc/typeof.qbk (props changed)
   branches/release/libs/utility/ (props changed)
   branches/release/libs/utility/assert.html (props changed)
   branches/release/libs/utility/assert_test.cpp (props changed)
   branches/release/libs/utility/swap.html (props changed)
   branches/release/libs/utility/swap/test/std_bitset.cpp (props changed)
   branches/release/libs/utility/value_init.htm (props changed)
   branches/release/libs/utility/value_init_test.cpp (props changed)
   branches/release/libs/uuid/ (props changed)
   branches/release/libs/wave/ (props changed)
   branches/release/more/ (props changed)
   branches/release/rst.css (props changed)
   branches/release/status/ (props changed)
   branches/release/status/Jamfile.v2 (props changed)
   branches/release/status/expected_results.xml (props changed)
   branches/release/status/explicit-failures-markup.xml (props changed)
   branches/release/status/explicit-failures.xsd (props changed)
   branches/release/tools/ (props changed)
   branches/release/tools/bcp/ (props changed)
   branches/release/tools/boostbook/ (props changed)
   branches/release/tools/build/v2/ (props changed)
   branches/release/tools/build/v2/tools/mpi.jam (props changed)
   branches/release/tools/inspect/ (props changed)
   branches/release/tools/quickbook/ (props changed)
   branches/release/tools/regression/ (props changed)
   branches/release/tools/regression/src/library_status.cpp (props changed)
   branches/release/tools/release/ (props changed)
   branches/release/tools/wave/ (props changed)
Text files modified:
   branches/release/boost/proto/proto_fwd.hpp | 10 +
   branches/release/boost/proto/traits.hpp | 65 +++++---
   branches/release/boost/proto/transform/call.hpp | 8
   branches/release/boost/proto/transform/make.hpp | 2
   branches/release/libs/proto/test/deduce_domain.cpp | 149 ++++++++++----------
   branches/release/libs/proto/test/make_expr.cpp | 252 +++++++++++++++++-----------------
   branches/release/libs/proto/test/matches.cpp | 283 ++++++++++++++++++++-------------------
   branches/release/libs/proto/test/switch.cpp | 25 +-
   8 files changed, 407 insertions(+), 387 deletions(-)

Modified: branches/release/boost/proto/proto_fwd.hpp
==============================================================================
--- branches/release/boost/proto/proto_fwd.hpp (original)
+++ branches/release/boost/proto/proto_fwd.hpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -187,6 +187,12 @@
         struct not_a_domain;
         struct not_a_grammar;
         struct not_a_generator;
+
+ template<typename T, typename Void = void>
+ struct is_transform_;
+
+ template<typename T, typename Void = void>
+ struct is_aggregate_;
     }
 
     typedef detail::ignore const ignore;
@@ -682,10 +688,10 @@
     template<typename T>
     struct is_callable;
 
- template<typename T, typename Void = void>
+ template<typename T>
     struct is_transform;
 
- template<typename T, typename Void = void>
+ template<typename T>
     struct is_aggregate;
 
     #define BOOST_PROTO_UNEXPR() typedef int proto_is_expr_;

Modified: branches/release/boost/proto/traits.hpp
==============================================================================
--- branches/release/boost/proto/traits.hpp (original)
+++ branches/release/boost/proto/traits.hpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -127,6 +127,19 @@
     {};
     #endif
 
+ namespace detail
+ {
+ template<typename T, typename Void /*= void*/>
+ struct is_transform_
+ : mpl::false_
+ {};
+
+ template<typename T>
+ struct is_transform_<T, typename T::proto_is_transform_>
+ : mpl::true_
+ {};
+ }
+
     /// \brief Boolean metafunction which detects whether a type is
     /// a PrimitiveTransform type or not.
     ///
@@ -142,15 +155,33 @@
     /// for \c void, <tt>is_transform\<T\>::value</tt> is \c true. (Note: this is
     /// the case for any type that derives from an instantiation of \c proto::transform.)
     /// \li Otherwise, <tt>is_transform\<T\>::value</tt> is \c false.
- template<typename T, typename Void /*= void*/>
+ template<typename T>
     struct is_transform
- : mpl::false_
+ : proto::detail::is_transform_<T>
     {};
 
- template<typename T>
- struct is_transform<T, typename T::proto_is_transform_>
- : mpl::true_
- {};
+ namespace detail
+ {
+ template<typename T, typename Void /*= void*/>
+ struct is_aggregate_
+ : is_pod<T>
+ {};
+
+ template<typename Tag, typename Args, long N>
+ struct is_aggregate_<proto::expr<Tag, Args, N>, void>
+ : mpl::true_
+ {};
+
+ template<typename Tag, typename Args, long N>
+ struct is_aggregate_<proto::basic_expr<Tag, Args, N>, void>
+ : mpl::true_
+ {};
+
+ template<typename T>
+ struct is_aggregate_<T, typename T::proto_is_aggregate_>
+ : mpl::true_
+ {};
+ }
 
     /// \brief A Boolean metafunction that indicates whether a type requires
     /// aggregate initialization.
@@ -161,27 +192,9 @@
     /// If <tt>is_aggregate\<T\>::value</tt> is \c true, then an object of
     /// type T will be initialized as <tt>T t = {a0,a1,...aN};</tt>. Otherwise,
     /// it will be initialized as <tt>T t(a0,a1,...aN)</tt>.
- template<typename T, typename Void>
- struct is_aggregate
- : is_pod<T>
- {};
-
- /// \brief Specialization of <tt>is_aggregate\<\></tt> that indicates
- /// that objects of <tt>expr\<\></tt> type require aggregate initialization.
- template<typename Tag, typename Args, long N>
- struct is_aggregate<proto::expr<Tag, Args, N>, void>
- : mpl::true_
- {};
-
- template<typename Tag, typename Args, long N>
- struct is_aggregate<proto::basic_expr<Tag, Args, N>, void>
- : mpl::true_
- {};
-
- /// INTERNAL ONLY
     template<typename T>
- struct is_aggregate<T, typename T::proto_is_aggregate_>
- : mpl::true_
+ struct is_aggregate
+ : proto::detail::is_aggregate_<T>
     {};
 
     /// \brief A Boolean metafunction that indicates whether a given

Modified: branches/release/boost/proto/transform/call.hpp
==============================================================================
--- branches/release/boost/proto/transform/call.hpp (original)
+++ branches/release/boost/proto/transform/call.hpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -124,7 +124,7 @@
         /// a typedef for <tt>boost::result_of\<Fun(Expr, State, Data)\>::type</tt>.
         template<typename Expr, typename State, typename Data>
         struct impl
- : impl2<Expr, State, Data, is_transform<Fun>::value>
+ : impl2<Expr, State, Data, detail::is_transform_<Fun>::value>
         {};
     };
 
@@ -193,7 +193,7 @@
         /// \param d An arbitrary data
         template<typename Expr, typename State, typename Data>
         struct impl
- : impl2<Expr, State, Data, is_transform<Fun>::value>
+ : impl2<Expr, State, Data, detail::is_transform_<Fun>::value>
         {};
     };
 
@@ -271,7 +271,7 @@
         /// \param d An arbitrary data
         template<typename Expr, typename State, typename Data>
         struct impl
- : impl2<Expr, State, Data, is_transform<Fun>::value>
+ : impl2<Expr, State, Data, detail::is_transform_<Fun>::value>
         {};
     };
 
@@ -337,7 +337,7 @@
 
         template<typename Expr, typename State, typename Data>
         struct impl
- : impl2<Expr, State, Data, is_transform<Fun>::value>
+ : impl2<Expr, State, Data, detail::is_transform_<Fun>::value>
         {};
     };
 

Modified: branches/release/boost/proto/transform/make.hpp
==============================================================================
--- branches/release/boost/proto/transform/make.hpp (original)
+++ branches/release/boost/proto/transform/make.hpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -112,7 +112,7 @@
         };
         #endif
 
- template<typename Type, bool IsAggregate = is_aggregate<Type>::value>
+ template<typename Type, bool IsAggregate = detail::is_aggregate_<Type>::value>
         struct construct_
         {
             typedef Type result_type;

Modified: branches/release/libs/proto/test/deduce_domain.cpp
==============================================================================
--- branches/release/libs/proto/test/deduce_domain.cpp (original)
+++ branches/release/libs/proto/test/deduce_domain.cpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -13,41 +13,42 @@
 #include <boost/mpl/assert.hpp>
 #include <boost/type_traits/is_same.hpp>
 
-using namespace boost::proto;
+namespace proto = boost::proto;
+using proto::_;
 
-struct D0 : domain<>
+struct D0 : proto::domain<>
 {
 };
 
-struct D1 : domain<default_generator, _, D0>
+struct D1 : proto::domain<proto::default_generator, _, D0>
 {
 };
 
-struct D2 : domain<default_generator, _, D0>
+struct D2 : proto::domain<proto::default_generator, _, D0>
 {
 };
 
-struct D3 : domain<>
+struct D3 : proto::domain<>
 {
 };
 
-struct DD0 : domain<default_generator, _, default_domain>
+struct DD0 : proto::domain<proto::default_generator, _, proto::default_domain>
 {
 };
 
-struct DD1 : domain<default_generator, _, default_domain>
+struct DD1 : proto::domain<proto::default_generator, _, proto::default_domain>
 {
 };
 
-struct DD2 : domain<default_generator, _, default_domain>
+struct DD2 : proto::domain<proto::default_generator, _, proto::default_domain>
 {
 };
 
-struct DD3 : domain<default_generator, _, DD2>
+struct DD3 : proto::domain<proto::default_generator, _, DD2>
 {
 };
 
-struct DD4 : domain<default_generator, _, DD2>
+struct DD4 : proto::domain<proto::default_generator, _, DD2>
 {
 };
 
@@ -56,74 +57,74 @@
     using boost::is_same;
 
     //*
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D0, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<default_domain, D0, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, default_domain, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D0, default_domain>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, default_domain, default_domain>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<default_domain, D0, default_domain>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<default_domain, default_domain, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<default_domain, default_domain, default_domain>::type, default_domain>));
-
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, D0, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, DD0, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D0, DD0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, DD0, DD0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, D0, DD0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, DD0, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<default_domain, DD0, DD0>::type, DD0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, default_domain, DD0>::type, DD0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, DD0, default_domain>::type, DD0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<default_domain, default_domain, DD0>::type, DD0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<default_domain, DD0, default_domain>::type, DD0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, DD0, default_domain>::type, DD0>));
-
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D0, D1>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D1, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D1, D1>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D0, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D0, D1>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D1, D0>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D1, D1>::type, D1>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D0, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<proto::default_domain, D0, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, proto::default_domain, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D0, proto::default_domain>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, proto::default_domain, proto::default_domain>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<proto::default_domain, D0, proto::default_domain>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<proto::default_domain, proto::default_domain, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<proto::default_domain, proto::default_domain, proto::default_domain>::type, proto::default_domain>));
+
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, D0, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, DD0, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D0, DD0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, DD0, DD0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, D0, DD0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, DD0, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<proto::default_domain, DD0, DD0>::type, DD0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, proto::default_domain, DD0>::type, DD0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, DD0, proto::default_domain>::type, DD0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<proto::default_domain, proto::default_domain, DD0>::type, DD0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<proto::default_domain, DD0, proto::default_domain>::type, DD0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, DD0, proto::default_domain>::type, DD0>));
+
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D0, D1>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D1, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D1, D1>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D0, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D0, D1>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D1, D0>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D1, D1>::type, D1>));
 
     // Very tricky to get right
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D2, D2, D1>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D2, D1, D2>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D2, D1, D1>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D2, D2>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D2, D1>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D1, D2>::type, D0>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D1, D1>::type, D1>));
-
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D3, D0, D0>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D3, D0>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D0, D3>::type, detail::not_a_domain>));
-
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D3, D1, D0>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D3, D0, D1>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D3, D0>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D3, D1>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D0, D1, D3>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D0, D3>::type, detail::not_a_domain>));
-
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D3, D1, D2>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D3, D2, D1>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D3, D2>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D2, D3, D1>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D2, D1, D3>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<D1, D2, D3>::type, detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D2, D2, D1>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D2, D1, D2>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D2, D1, D1>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D2, D2>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D2, D1>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D1, D2>::type, D0>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D1, D1>::type, D1>));
+
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D3, D0, D0>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D3, D0>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D0, D3>::type, proto::detail::not_a_domain>));
+
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D3, D1, D0>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D3, D0, D1>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D3, D0>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D3, D1>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D0, D1, D3>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D0, D3>::type, proto::detail::not_a_domain>));
+
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D3, D1, D2>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D3, D2, D1>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D3, D2>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D2, D3, D1>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D2, D1, D3>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<D1, D2, D3>::type, proto::detail::not_a_domain>));
 
     // These should be ambiguous.
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD1, DD0, DD0>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, DD1, DD0>::type, detail::not_a_domain>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD0, DD0, DD1>::type, detail::not_a_domain>));
-
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD3, DD2, DD2>::type, DD2>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD2, DD3, DD2>::type, DD2>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD2, DD2, DD3>::type, DD2>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD3, DD4, DD4>::type, DD2>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD4, DD3, DD4>::type, DD2>));
- BOOST_MPL_ASSERT((is_same<detail::common_domain3<DD4, DD4, DD3>::type, DD2>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD1, DD0, DD0>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, DD1, DD0>::type, proto::detail::not_a_domain>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD0, DD0, DD1>::type, proto::detail::not_a_domain>));
+
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD3, DD2, DD2>::type, DD2>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD2, DD3, DD2>::type, DD2>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD2, DD2, DD3>::type, DD2>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD3, DD4, DD4>::type, DD2>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD4, DD3, DD4>::type, DD2>));
+ BOOST_MPL_ASSERT((is_same<proto::detail::common_domain3<DD4, DD4, DD3>::type, DD2>));
     //*/
 }
 

Modified: branches/release/libs/proto/test/make_expr.cpp
==============================================================================
--- branches/release/libs/proto/test/make_expr.cpp (original)
+++ branches/release/libs/proto/test/make_expr.cpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// make_expr.hpp
+// proto::make_expr.hpp
 //
 // Copyright 2008 Eric Niebler. Distributed under the Boost
 // Software License, Version 1.0. (See accompanying file
@@ -12,282 +12,282 @@
 #include <boost/fusion/tuple.hpp>
 #include <boost/test/unit_test.hpp>
 
-using namespace boost;
-using namespace proto;
+namespace fusion = boost::fusion;
+namespace proto = boost::proto;
 
 template<typename E> struct ewrap;
 
 struct mydomain
- : domain<generator<ewrap> >
+ : proto::domain<proto::generator<ewrap> >
 {};
 
 template<typename E> struct ewrap
- : extends<E, ewrap<E>, mydomain>
+ : proto::extends<E, ewrap<E>, mydomain>
 {
     explicit ewrap(E const &e = E())
- : extends<E, ewrap<E>, mydomain>(e)
+ : proto::extends<E, ewrap<E>, mydomain>(e)
     {}
 };
 
 void test_make_expr()
 {
     int i = 42;
- terminal<int>::type t1 = make_expr<tag::terminal>(1);
- terminal<int>::type t2 = make_expr<tag::terminal>(i);
- unary_plus<terminal<int>::type>::type p1 = make_expr<tag::unary_plus>(1);
- unary_plus<terminal<int>::type>::type p2 = make_expr<tag::unary_plus>(i);
+ proto::terminal<int>::type t1 = proto::make_expr<proto::tag::terminal>(1);
+ proto::terminal<int>::type t2 = proto::make_expr<proto::tag::terminal>(i);
+ proto::unary_plus<proto::terminal<int>::type>::type p1 = proto::make_expr<proto::tag::unary_plus>(1);
+ proto::unary_plus<proto::terminal<int>::type>::type p2 = proto::make_expr<proto::tag::unary_plus>(i);
     BOOST_CHECK_EQUAL(proto::value(proto::child(p2)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::unary_plus
+ proto::tag::unary_plus
               , proto::list1<
- ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p3_type;
- p3_type p3 = make_expr<tag::unary_plus, mydomain>(i);
+ p3_type p3 = proto::make_expr<proto::tag::unary_plus, mydomain>(i);
     BOOST_CHECK_EQUAL(proto::value(proto::child(p3)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::plus
+ proto::tag::plus
               , proto::list2<
                     p3_type
- , ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ , ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p4_type;
- p4_type p4 = make_expr<tag::plus>(p3, 0);
+ p4_type p4 = proto::make_expr<proto::tag::plus>(p3, 0);
     BOOST_CHECK_EQUAL(proto::value(proto::child(proto::left(p4))), 42);
 }
 
 void test_make_expr_ref()
 {
     int i = 42;
- terminal<int const &>::type t1 = make_expr<tag::terminal>(boost::cref(1)); // DANGEROUS
- terminal<int &>::type t2 = make_expr<tag::terminal>(boost::ref(i));
+ proto::terminal<int const &>::type t1 = proto::make_expr<proto::tag::terminal>(boost::cref(1)); // DANGEROUS
+ proto::terminal<int &>::type t2 = proto::make_expr<proto::tag::terminal>(boost::ref(i));
     BOOST_CHECK_EQUAL(&i, &proto::value(t2));
- unary_plus<terminal<int const &>::type>::type p1 = make_expr<tag::unary_plus>(boost::cref(1)); // DANGEROUS
- unary_plus<terminal<int &>::type>::type p2 = make_expr<tag::unary_plus>(boost::ref(i));
+ proto::unary_plus<proto::terminal<int const &>::type>::type p1 = proto::make_expr<proto::tag::unary_plus>(boost::cref(1)); // DANGEROUS
+ proto::unary_plus<proto::terminal<int &>::type>::type p2 = proto::make_expr<proto::tag::unary_plus>(boost::ref(i));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p2)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::unary_plus
+ proto::tag::unary_plus
               , proto::list1<
- ewrap<proto::basic_expr<tag::terminal, proto::term<int &> > >
+ ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int &> > >
>
>
>
     p3_type;
- p3_type p3 = make_expr<tag::unary_plus, mydomain>(boost::ref(i));
+ p3_type p3 = proto::make_expr<proto::tag::unary_plus, mydomain>(boost::ref(i));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p3)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::plus
+ proto::tag::plus
               , proto::list2<
                     p3_type &
- , ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ , ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p4_type;
- p4_type p4 = make_expr<tag::plus>(boost::ref(p3), 0);
+ p4_type p4 = proto::make_expr<proto::tag::plus>(boost::ref(p3), 0);
     BOOST_CHECK_EQUAL(proto::value(proto::child(proto::left(p4))), 42);
 }
 
 void test_make_expr_functional()
 {
     int i = 42;
- terminal<int>::type t1 = functional::make_expr<tag::terminal>()(1);
- terminal<int>::type t2 = functional::make_expr<tag::terminal>()(i);
- unary_plus<terminal<int>::type>::type p1 = functional::make_expr<tag::unary_plus>()(1);
- unary_plus<terminal<int>::type>::type p2 = functional::make_expr<tag::unary_plus>()(i);
+ proto::terminal<int>::type t1 = proto::functional::make_expr<proto::tag::terminal>()(1);
+ proto::terminal<int>::type t2 = proto::functional::make_expr<proto::tag::terminal>()(i);
+ proto::unary_plus<proto::terminal<int>::type>::type p1 = proto::functional::make_expr<proto::tag::unary_plus>()(1);
+ proto::unary_plus<proto::terminal<int>::type>::type p2 = proto::functional::make_expr<proto::tag::unary_plus>()(i);
     BOOST_CHECK_EQUAL(proto::value(proto::child(p2)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::unary_plus
+ proto::tag::unary_plus
               , proto::list1<
- ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p3_type;
- p3_type p3 = functional::make_expr<tag::unary_plus, mydomain>()(i);
+ p3_type p3 = proto::functional::make_expr<proto::tag::unary_plus, mydomain>()(i);
     BOOST_CHECK_EQUAL(proto::value(proto::child(p3)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::plus
+ proto::tag::plus
               , proto::list2<
                     p3_type
- , ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ , ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p4_type;
- p4_type p4 = functional::make_expr<tag::plus>()(p3, 0);
+ p4_type p4 = proto::functional::make_expr<proto::tag::plus>()(p3, 0);
 }
 
 void test_make_expr_functional_ref()
 {
     int i = 42;
- terminal<int const &>::type t1 = functional::make_expr<tag::terminal>()(boost::cref(1)); // DANGEROUS
- terminal<int &>::type t2 = functional::make_expr<tag::terminal>()(boost::ref(i));
+ proto::terminal<int const &>::type t1 = proto::functional::make_expr<proto::tag::terminal>()(boost::cref(1)); // DANGEROUS
+ proto::terminal<int &>::type t2 = proto::functional::make_expr<proto::tag::terminal>()(boost::ref(i));
     BOOST_CHECK_EQUAL(&i, &proto::value(t2));
- unary_plus<terminal<int const &>::type>::type p1 = functional::make_expr<tag::unary_plus>()(boost::cref(1)); // DANGEROUS
- unary_plus<terminal<int &>::type>::type p2 = functional::make_expr<tag::unary_plus>()(boost::ref(i));
+ proto::unary_plus<proto::terminal<int const &>::type>::type p1 = proto::functional::make_expr<proto::tag::unary_plus>()(boost::cref(1)); // DANGEROUS
+ proto::unary_plus<proto::terminal<int &>::type>::type p2 = proto::functional::make_expr<proto::tag::unary_plus>()(boost::ref(i));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p2)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::unary_plus
+ proto::tag::unary_plus
               , proto::list1<
- ewrap<proto::basic_expr<tag::terminal, proto::term<int &> > >
+ ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int &> > >
>
>
>
     p3_type;
- p3_type p3 = functional::make_expr<tag::unary_plus, mydomain>()(boost::ref(i));
+ p3_type p3 = proto::functional::make_expr<proto::tag::unary_plus, mydomain>()(boost::ref(i));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p3)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::plus
+ proto::tag::plus
               , proto::list2<
                     p3_type &
- , ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ , ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p4_type;
- p4_type p4 = functional::make_expr<tag::plus>()(boost::ref(p3), 0);
+ p4_type p4 = proto::functional::make_expr<proto::tag::plus>()(boost::ref(p3), 0);
     BOOST_CHECK_EQUAL(proto::value(proto::child(proto::left(p4))), 42);
 }
 
 void test_unpack_expr()
 {
     int i = 42;
- terminal<int>::type t1 = unpack_expr<tag::terminal>(fusion::make_tuple(1));
- terminal<int &>::type t2 = unpack_expr<tag::terminal>(fusion::make_tuple(boost::ref(i)));
- unary_plus<terminal<int>::type>::type p1 = unpack_expr<tag::unary_plus>(fusion::make_tuple(1));
- unary_plus<terminal<int &>::type>::type p2 = unpack_expr<tag::unary_plus>(fusion::make_tuple(boost::ref(i)));
+ proto::terminal<int>::type t1 = proto::unpack_expr<proto::tag::terminal>(fusion::make_tuple(1));
+ proto::terminal<int &>::type t2 = proto::unpack_expr<proto::tag::terminal>(fusion::make_tuple(boost::ref(i)));
+ proto::unary_plus<proto::terminal<int>::type>::type p1 = proto::unpack_expr<proto::tag::unary_plus>(fusion::make_tuple(1));
+ proto::unary_plus<proto::terminal<int &>::type>::type p2 = proto::unpack_expr<proto::tag::unary_plus>(fusion::make_tuple(boost::ref(i)));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p2)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::unary_plus
+ proto::tag::unary_plus
               , proto::list1<
- ewrap<proto::basic_expr<tag::terminal, proto::term<int &> > >
+ ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int &> > >
>
>
>
     p3_type;
- p3_type p3 = unpack_expr<tag::unary_plus, mydomain>(fusion::make_tuple(boost::ref(i)));
+ p3_type p3 = proto::unpack_expr<proto::tag::unary_plus, mydomain>(fusion::make_tuple(boost::ref(i)));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p3)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::plus
+ proto::tag::plus
               , proto::list2<
                     p3_type &
- , ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ , ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p4_type;
- p4_type p4 = unpack_expr<tag::plus>(fusion::make_tuple(boost::ref(p3), 0));
+ p4_type p4 = proto::unpack_expr<proto::tag::plus>(fusion::make_tuple(boost::ref(p3), 0));
     BOOST_CHECK_EQUAL(proto::value(proto::child(proto::left(p4))), 42);
 }
 
 void test_unpack_expr_functional()
 {
     int i = 42;
- terminal<int>::type t1 = functional::unpack_expr<tag::terminal>()(fusion::make_tuple(1));
- terminal<int &>::type t2 = functional::unpack_expr<tag::terminal>()(fusion::make_tuple(boost::ref(i)));
- unary_plus<terminal<int>::type>::type p1 = functional::unpack_expr<tag::unary_plus>()(fusion::make_tuple(1));
- unary_plus<terminal<int &>::type>::type p2 = functional::unpack_expr<tag::unary_plus>()(fusion::make_tuple(boost::ref(i)));
+ proto::terminal<int>::type t1 = proto::functional::unpack_expr<proto::tag::terminal>()(fusion::make_tuple(1));
+ proto::terminal<int &>::type t2 = proto::functional::unpack_expr<proto::tag::terminal>()(fusion::make_tuple(boost::ref(i)));
+ proto::unary_plus<proto::terminal<int>::type>::type p1 = proto::functional::unpack_expr<proto::tag::unary_plus>()(fusion::make_tuple(1));
+ proto::unary_plus<proto::terminal<int &>::type>::type p2 = proto::functional::unpack_expr<proto::tag::unary_plus>()(fusion::make_tuple(boost::ref(i)));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p2)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::unary_plus
+ proto::tag::unary_plus
               , proto::list1<
- ewrap<proto::basic_expr<tag::terminal, proto::term<int &> > >
+ ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int &> > >
>
>
>
     p3_type;
- p3_type p3 = functional::unpack_expr<tag::unary_plus, mydomain>()(fusion::make_tuple(boost::ref(i)));
+ p3_type p3 = proto::functional::unpack_expr<proto::tag::unary_plus, mydomain>()(fusion::make_tuple(boost::ref(i)));
     BOOST_CHECK_EQUAL(proto::value(proto::child(p3)), 42);
 
     typedef
         ewrap<
             proto::basic_expr<
- tag::plus
+ proto::tag::plus
               , proto::list2<
                     p3_type &
- , ewrap<proto::basic_expr<tag::terminal, proto::term<int> > >
+ , ewrap<proto::basic_expr<proto::tag::terminal, proto::term<int> > >
>
>
>
     p4_type;
- p4_type p4 = functional::unpack_expr<tag::plus>()(fusion::make_tuple(boost::ref(p3), 0));
+ p4_type p4 = proto::functional::unpack_expr<proto::tag::plus>()(fusion::make_tuple(boost::ref(p3), 0));
     BOOST_CHECK_EQUAL(proto::value(proto::child(proto::left(p4))), 42);
 }
 
 #if BOOST_WORKAROUND(BOOST_MSVC, == 1310)
-#define _byref(x) call<_byref(x)>
-#define _byval(x) call<_byval(x)>
-#define Minus(x) call<Minus(x)>
+#define _byref(x) call<proto::_byref(x)>
+#define _byval(x) call<proto::_byval(x)>
+#define Minus(x) proto::call<Minus(x)>
 #endif
 
 // Turn all terminals held by reference into ones held by value
 struct ByVal
- : or_<
- when<terminal<_>, _make_terminal(_byval(_value))>
- , when<nary_expr<_, vararg<ByVal> > >
+ : proto::or_<
+ proto::when<proto::terminal<proto::_>, proto::_make_terminal(proto::_byval(proto::_value))>
+ , proto::when<proto::nary_expr<proto::_, proto::vararg<ByVal> > >
>
 {};
 
 // Turn all terminals held by value into ones held by reference (not safe in general)
 struct ByRef
- : or_<
- when<terminal<_>, _make_terminal(_byref(_value))>
- , when<nary_expr<_, vararg<ByRef> > >
+ : proto::or_<
+ proto::when<proto::terminal<proto::_>, proto::_make_terminal(proto::_byref(proto::_value))>
+ , proto::when<proto::nary_expr<proto::_, proto::vararg<ByRef> > >
>
 {};
 
-// turn all plus nodes to minus nodes:
+// turn all proto::plus nodes to minus nodes:
 struct Minus
- : or_<
- when<terminal<_> >
- , when<plus<Minus, Minus>, _make_minus(Minus(_left), Minus(_right)) >
+ : proto::or_<
+ proto::when<proto::terminal<proto::_> >
+ , proto::when<proto::plus<Minus, Minus>, proto::_make_minus(Minus(proto::_left), Minus(proto::_right)) >
>
 {};
 
 struct Square
- : or_<
- // Not creating new terminal nodes here,
+ : proto::or_<
+ // Not creating new proto::terminal nodes here,
         // so hold the existing terminals by reference:
- when<terminal<_>, _make_multiplies(_, _)>
- , when<plus<Square, Square> >
+ proto::when<proto::terminal<proto::_>, proto::_make_multiplies(proto::_, proto::_)>
+ , proto::when<proto::plus<Square, Square> >
>
 {};
 
@@ -299,61 +299,61 @@
 
 void test_make_expr_transform()
 {
- plus<
- terminal<int>::type
- , terminal<int>::type
- >::type t1 = ByVal()(as_expr(1) + 1);
-
- plus<
- terminal<int const &>::type
- , terminal<int const &>::type
- >::type t2 = ByRef()(as_expr(1) + 1);
-
- minus<
- terminal<int>::type const &
- , terminal<int const &>::type const &
- >::type t3 = Minus()(as_expr(1) + 1);
-
- plus<
- multiplies<terminal<int>::type const &, terminal<int>::type const &>::type
- , multiplies<terminal<int const &>::type const &, terminal<int const &>::type const &>::type
- >::type t4 = Square()(as_expr(1) + 1);
+ proto::plus<
+ proto::terminal<int>::type
+ , proto::terminal<int>::type
+ >::type t1 = ByVal()(proto::as_expr(1) + 1);
+
+ proto::plus<
+ proto::terminal<int const &>::type
+ , proto::terminal<int const &>::type
+ >::type t2 = ByRef()(proto::as_expr(1) + 1);
+
+ proto::minus<
+ proto::terminal<int>::type const &
+ , proto::terminal<int const &>::type const &
+ >::type t3 = Minus()(proto::as_expr(1) + 1);
+
+ proto::plus<
+ proto::multiplies<proto::terminal<int>::type const &, proto::terminal<int>::type const &>::type
+ , proto::multiplies<proto::terminal<int const &>::type const &, proto::terminal<int const &>::type const &>::type
+ >::type t4 = Square()(proto::as_expr(1) + 1);
 }
 
 
 struct length_impl {};
 struct dot_impl {};
 
-terminal<length_impl>::type const length = {{}};
-terminal<dot_impl>::type const dot = {{}};
+proto::terminal<length_impl>::type const length = {{}};
+proto::terminal<dot_impl>::type const dot = {{}};
 
 // work around msvc bugs...
 #if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1500))
-#define _byref(a) call<_byref(a)>
-#define _byval(a) call<_byval(a)>
-#define _child1(a) call<_child1(a)>
-#define _make_terminal(a) call<_make_terminal(a)>
-#define _make_function(a,b,c) call<_make_function(a,b,c)>
-#define dot_impl() make<dot_impl()>
+#define _byref(a) call<proto::_byref(a)>
+#define _byval(a) call<proto::_byval(a)>
+#define _child1(a) call<proto::_child1(a)>
+#define _make_terminal(a) call<proto::_make_terminal(a)>
+#define _make_function(a,b,c) call<proto::_make_function(a,b,c)>
+#define dot_impl() proto::make<dot_impl()>
 #endif
 
 // convert length(a) < length(b) to dot(a,a) < dot(b,b)
 struct Convert
- : when<
- less<
- function<terminal<length_impl>, _>
- , function<terminal<length_impl>, _>
- >
- , _make_less(
- _make_function(
- _make_terminal(dot_impl())
- , _child1(_child0)
- , _child1(_child0)
+ : proto::when<
+ proto::less<
+ proto::function<proto::terminal<length_impl>, proto::_>
+ , proto::function<proto::terminal<length_impl>, proto::_>
+ >
+ , proto::_make_less(
+ proto::_make_function(
+ proto::_make_terminal(dot_impl())
+ , proto::_child1(proto::_child0)
+ , proto::_child1(proto::_child0)
             )
- , _make_function(
- _make_terminal(dot_impl())
- , _child1(_child1)
- , _child1(_child1)
+ , proto::_make_function(
+ proto::_make_terminal(dot_impl())
+ , proto::_child1(proto::_child1)
+ , proto::_child1(proto::_child1)
             )
         )
>
@@ -384,13 +384,13 @@
 #undef dot_impl
 #endif
 
-using namespace unit_test;
+using namespace boost::unit_test;
 ///////////////////////////////////////////////////////////////////////////////
 // init_unit_test_suite
 //
 test_suite* init_unit_test_suite( int argc, char* argv[] )
 {
- test_suite *test = BOOST_TEST_SUITE("test make_expr, unpack_expr and friends");
+ test_suite *test = BOOST_TEST_SUITE("test proto::make_expr, proto::unpack_expr and friends");
 
     test->add(BOOST_TEST_CASE(&test_make_expr));
     test->add(BOOST_TEST_CASE(&test_make_expr_ref));

Modified: branches/release/libs/proto/test/matches.cpp
==============================================================================
--- branches/release/libs/proto/test/matches.cpp (original)
+++ branches/release/libs/proto/test/matches.cpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -17,8 +17,9 @@
 #include <boost/proto/transform/arg.hpp>
 #include <boost/test/unit_test.hpp>
 
-using namespace boost;
-using namespace proto;
+namespace mpl = boost::mpl;
+namespace proto = boost::proto;
+namespace fusion = boost::fusion;
 
 struct int_convertible
 {
@@ -27,26 +28,26 @@
 };
 
 struct Input
- : or_<
- shift_right< terminal< std::istream & >, _ >
- , shift_right< Input, _ >
+ : proto::or_<
+ proto::shift_right< proto::terminal< std::istream & >, proto::_ >
+ , proto::shift_right< Input, proto::_ >
>
 {};
 
 struct Output
- : or_<
- shift_left< terminal< std::ostream & >, _ >
- , shift_left< Output, _ >
+ : proto::or_<
+ proto::shift_left< proto::terminal< std::ostream & >, proto::_ >
+ , proto::shift_left< Output, proto::_ >
>
 {};
 
-terminal< std::istream & >::type const cin_ = {std::cin};
-terminal< std::ostream & >::type const cout_ = {std::cout};
+proto::terminal< std::istream & >::type const cin_ = {std::cin};
+proto::terminal< std::ostream & >::type const cout_ = {std::cout};
 
 struct Anything
- : or_<
- terminal<_>
- , nary_expr<_, vararg<Anything> >
+ : proto::or_<
+ proto::terminal<proto::_>
+ , proto::nary_expr<proto::_, proto::vararg<Anything> >
>
 {};
 
@@ -117,92 +118,92 @@
 
 void test_matches()
 {
- assert_matches< _ >( lit(1) );
- assert_matches< _ >( as_child(1) );
- assert_matches< _ >( as_expr(1) );
-
- assert_matches< terminal<int> >( lit(1) );
- assert_matches< terminal<int> >( as_child(1) );
- assert_matches< terminal<int> >( as_expr(1) );
-
- assert_matches_not< terminal<int> >( lit('a') );
- assert_matches_not< terminal<int> >( as_child('a') );
- assert_matches_not< terminal<int> >( as_expr('a') );
-
- assert_matches< terminal<convertible_to<int> > >( lit('a') );
- assert_matches< terminal<convertible_to<int> > >( as_child('a') );
- assert_matches< terminal<convertible_to<int> > >( as_expr('a') );
-
- assert_matches_not< terminal<int> >( lit((int_convertible())) );
- assert_matches_not< terminal<int> >( as_child((int_convertible())) );
- assert_matches_not< terminal<int> >( as_expr((int_convertible())) );
-
- assert_matches< terminal<convertible_to<int> > >( lit((int_convertible())) );
- assert_matches< terminal<convertible_to<int> > >( as_child((int_convertible())) );
- assert_matches< terminal<convertible_to<int> > >( as_expr((int_convertible())) );
-
- assert_matches< if_<is_same<_value, int>() > >( lit(1) );
- assert_matches_not< if_<is_same<_value, int>() > >( lit('a') );
-
- assert_matches<
- and_<
- terminal<_>
- , if_<is_same<_value, int>() >
+ proto::assert_matches< proto::_ >( proto::lit(1) );
+ proto::assert_matches< proto::_ >( proto::as_child(1) );
+ proto::assert_matches< proto::_ >( proto::as_expr(1) );
+
+ proto::assert_matches< proto::terminal<int> >( proto::lit(1) );
+ proto::assert_matches< proto::terminal<int> >( proto::as_child(1) );
+ proto::assert_matches< proto::terminal<int> >( proto::as_expr(1) );
+
+ proto::assert_matches_not< proto::terminal<int> >( proto::lit('a') );
+ proto::assert_matches_not< proto::terminal<int> >( proto::as_child('a') );
+ proto::assert_matches_not< proto::terminal<int> >( proto::as_expr('a') );
+
+ proto::assert_matches< proto::terminal<proto::convertible_to<int> > >( proto::lit('a') );
+ proto::assert_matches< proto::terminal<proto::convertible_to<int> > >( proto::as_child('a') );
+ proto::assert_matches< proto::terminal<proto::convertible_to<int> > >( proto::as_expr('a') );
+
+ proto::assert_matches_not< proto::terminal<int> >( proto::lit((int_convertible())) );
+ proto::assert_matches_not< proto::terminal<int> >( proto::as_child((int_convertible())) );
+ proto::assert_matches_not< proto::terminal<int> >( proto::as_expr((int_convertible())) );
+
+ proto::assert_matches< proto::terminal<proto::convertible_to<int> > >( proto::lit((int_convertible())) );
+ proto::assert_matches< proto::terminal<proto::convertible_to<int> > >( proto::as_child((int_convertible())) );
+ proto::assert_matches< proto::terminal<proto::convertible_to<int> > >( proto::as_expr((int_convertible())) );
+
+ proto::assert_matches< proto::if_<boost::is_same<proto::_value, int>() > >( proto::lit(1) );
+ proto::assert_matches_not< proto::if_<boost::is_same<proto::_value, int>() > >( proto::lit('a') );
+
+ proto::assert_matches<
+ proto::and_<
+ proto::terminal<proto::_>
+ , proto::if_<boost::is_same<proto::_value, int>() >
>
- >( lit(1) );
+ >( proto::lit(1) );
 
- assert_matches_not<
- and_<
- terminal<_>
- , if_<is_same<_value, int>() >
+ proto::assert_matches_not<
+ proto::and_<
+ proto::terminal<proto::_>
+ , proto::if_<boost::is_same<proto::_value, int>() >
>
- >( lit('a') );
+ >( proto::lit('a') );
 
- assert_matches< terminal<char const *> >( lit("hello") );
- assert_matches< terminal<char const *> >( as_child("hello") );
- assert_matches< terminal<char const *> >( as_expr("hello") );
+ proto::assert_matches< proto::terminal<char const *> >( proto::lit("hello") );
+ proto::assert_matches< proto::terminal<char const *> >( proto::as_child("hello") );
+ proto::assert_matches< proto::terminal<char const *> >( proto::as_expr("hello") );
 
- assert_matches< terminal<char const[6]> >( lit("hello") );
- assert_matches< terminal<char const (&)[6]> >( as_child("hello") );
- assert_matches< terminal<char const[6]> >( as_expr("hello") );
+ proto::assert_matches< proto::terminal<char const[6]> >( proto::lit("hello") );
+ proto::assert_matches< proto::terminal<char const (&)[6]> >( proto::as_child("hello") );
+ proto::assert_matches< proto::terminal<char const[6]> >( proto::as_expr("hello") );
 
- assert_matches< terminal<char [6]> >( lit("hello") );
- assert_matches< terminal<char [6]> >( as_child("hello") );
- assert_matches< terminal<char [6]> >( as_expr("hello") );
+ proto::assert_matches< proto::terminal<char [6]> >( proto::lit("hello") );
+ proto::assert_matches< proto::terminal<char [6]> >( proto::as_child("hello") );
+ proto::assert_matches< proto::terminal<char [6]> >( proto::as_expr("hello") );
 
- assert_matches< terminal<char const[N]> >( lit("hello") );
- assert_matches< terminal<char const (&)[N]> >( as_child("hello") );
- assert_matches< terminal<char const[N]> >( as_expr("hello") );
+ proto::assert_matches< proto::terminal<char const[proto::N]> >( proto::lit("hello") );
+ proto::assert_matches< proto::terminal<char const (&)[proto::N]> >( proto::as_child("hello") );
+ proto::assert_matches< proto::terminal<char const[proto::N]> >( proto::as_expr("hello") );
 
- assert_matches< terminal<char [N]> >( lit("hello") );
- assert_matches< terminal<char [N]> >( as_child("hello") );
- assert_matches< terminal<char [N]> >( as_expr("hello") );
+ proto::assert_matches< proto::terminal<char [proto::N]> >( proto::lit("hello") );
+ proto::assert_matches< proto::terminal<char [proto::N]> >( proto::as_child("hello") );
+ proto::assert_matches< proto::terminal<char [proto::N]> >( proto::as_expr("hello") );
 
- assert_matches< terminal<wchar_t const[N]> >( lit(L"hello") );
- assert_matches< terminal<wchar_t const (&)[N]> >( as_child(L"hello") );
- assert_matches< terminal<wchar_t const[N]> >( as_expr(L"hello") );
+ proto::assert_matches< proto::terminal<wchar_t const[proto::N]> >( proto::lit(L"hello") );
+ proto::assert_matches< proto::terminal<wchar_t const (&)[proto::N]> >( proto::as_child(L"hello") );
+ proto::assert_matches< proto::terminal<wchar_t const[proto::N]> >( proto::as_expr(L"hello") );
 
- assert_matches< terminal<wchar_t [N]> >( lit(L"hello") );
- assert_matches< terminal<wchar_t [N]> >( as_child(L"hello") );
- assert_matches< terminal<wchar_t [N]> >( as_expr(L"hello") );
+ proto::assert_matches< proto::terminal<wchar_t [proto::N]> >( proto::lit(L"hello") );
+ proto::assert_matches< proto::terminal<wchar_t [proto::N]> >( proto::as_child(L"hello") );
+ proto::assert_matches< proto::terminal<wchar_t [proto::N]> >( proto::as_expr(L"hello") );
 
- assert_matches_not< if_<is_same<_value, int>()> >( lit("hello") );
+ proto::assert_matches_not< proto::if_<boost::is_same<proto::_value, int>()> >( proto::lit("hello") );
 
- assert_matches< terminal<std::string> >( lit(std::string("hello")) );
- assert_matches< terminal<std::string> >( as_child(std::string("hello")) );
- assert_matches< terminal<std::string> >( as_expr(std::string("hello")) );
+ proto::assert_matches< proto::terminal<std::string> >( proto::lit(std::string("hello")) );
+ proto::assert_matches< proto::terminal<std::string> >( proto::as_child(std::string("hello")) );
+ proto::assert_matches< proto::terminal<std::string> >( proto::as_expr(std::string("hello")) );
 
- assert_matches< terminal<std::basic_string<_> > >( lit(std::string("hello")) );
- assert_matches< terminal<std::basic_string<_> > >( as_child(std::string("hello")) );
- assert_matches< terminal<std::basic_string<_> > >( as_expr(std::string("hello")) );
+ proto::assert_matches< proto::terminal<std::basic_string<proto::_> > >( proto::lit(std::string("hello")) );
+ proto::assert_matches< proto::terminal<std::basic_string<proto::_> > >( proto::as_child(std::string("hello")) );
+ proto::assert_matches< proto::terminal<std::basic_string<proto::_> > >( proto::as_expr(std::string("hello")) );
 
- assert_matches_not< terminal<std::basic_string<_> > >( lit(1) );
- assert_matches_not< terminal<std::basic_string<_> > >( as_child(1) );
- assert_matches_not< terminal<std::basic_string<_> > >( as_expr(1) );
+ proto::assert_matches_not< proto::terminal<std::basic_string<proto::_> > >( proto::lit(1) );
+ proto::assert_matches_not< proto::terminal<std::basic_string<proto::_> > >( proto::as_child(1) );
+ proto::assert_matches_not< proto::terminal<std::basic_string<proto::_> > >( proto::as_expr(1) );
 
- assert_matches_not< terminal<std::basic_string<_,_,_> > >( lit(1) );
- assert_matches_not< terminal<std::basic_string<_,_,_> > >( as_child(1) );
- assert_matches_not< terminal<std::basic_string<_,_,_> > >( as_expr(1) );
+ proto::assert_matches_not< proto::terminal<std::basic_string<proto::_,proto::_,proto::_> > >( proto::lit(1) );
+ proto::assert_matches_not< proto::terminal<std::basic_string<proto::_,proto::_,proto::_> > >( proto::as_child(1) );
+ proto::assert_matches_not< proto::terminal<std::basic_string<proto::_,proto::_,proto::_> > >( proto::as_expr(1) );
 
     #if BOOST_WORKAROUND(__HP_aCC, BOOST_TESTED_AT(61700))
     typedef std::string const const_string;
@@ -210,100 +211,100 @@
     typedef std::string const_string;
     #endif
     
- assert_matches< terminal<std::basic_string<_> const & > >( lit(const_string("hello")) );
- assert_matches< terminal<std::basic_string<_> const & > >( as_child(const_string("hello")) );
- assert_matches_not< terminal<std::basic_string<_> const & > >( as_expr(const_string("hello")) );
-
- assert_matches< terminal< void(&)() > >( lit(a_function) );
- assert_matches< terminal< void(&)() > >( as_child(a_function) );
- assert_matches< terminal< void(&)() > >( as_expr(a_function) );
-
- assert_matches_not< terminal< void(*)() > >( lit(a_function) );
- assert_matches_not< terminal< void(*)() > >( as_child(a_function) );
- assert_matches_not< terminal< void(*)() > >( as_expr(a_function) );
-
- assert_matches< terminal< convertible_to<void(*)()> > >( lit(a_function) );
- assert_matches< terminal< convertible_to<void(*)()> > >( as_child(a_function) );
- assert_matches< terminal< convertible_to<void(*)()> > >( as_expr(a_function) );
-
- assert_matches< terminal< void(*)() > >( lit(&a_function) );
- assert_matches< terminal< void(*)() > >( as_child(&a_function) );
- assert_matches< terminal< void(*)() > >( as_expr(&a_function) );
-
- assert_matches< terminal< void(* const &)() > >( lit(&a_function) );
- assert_matches< terminal< void(* const &)() > >( as_child(&a_function) );
- assert_matches_not< terminal< void(* const &)() > >( as_expr(&a_function) );
-
- assert_matches<
- or_<
- if_<is_same<_value, char>() >
- , if_<is_same<_value, int>() >
+ proto::assert_matches< proto::terminal<std::basic_string<proto::_> const & > >( proto::lit(const_string("hello")) );
+ proto::assert_matches< proto::terminal<std::basic_string<proto::_> const & > >( proto::as_child(const_string("hello")) );
+ proto::assert_matches_not< proto::terminal<std::basic_string<proto::_> const & > >( proto::as_expr(const_string("hello")) );
+
+ proto::assert_matches< proto::terminal< void(&)() > >( proto::lit(a_function) );
+ proto::assert_matches< proto::terminal< void(&)() > >( proto::as_child(a_function) );
+ proto::assert_matches< proto::terminal< void(&)() > >( proto::as_expr(a_function) );
+
+ proto::assert_matches_not< proto::terminal< void(*)() > >( proto::lit(a_function) );
+ proto::assert_matches_not< proto::terminal< void(*)() > >( proto::as_child(a_function) );
+ proto::assert_matches_not< proto::terminal< void(*)() > >( proto::as_expr(a_function) );
+
+ proto::assert_matches< proto::terminal< proto::convertible_to<void(*)()> > >( proto::lit(a_function) );
+ proto::assert_matches< proto::terminal< proto::convertible_to<void(*)()> > >( proto::as_child(a_function) );
+ proto::assert_matches< proto::terminal< proto::convertible_to<void(*)()> > >( proto::as_expr(a_function) );
+
+ proto::assert_matches< proto::terminal< void(*)() > >( proto::lit(&a_function) );
+ proto::assert_matches< proto::terminal< void(*)() > >( proto::as_child(&a_function) );
+ proto::assert_matches< proto::terminal< void(*)() > >( proto::as_expr(&a_function) );
+
+ proto::assert_matches< proto::terminal< void(* const &)() > >( proto::lit(&a_function) );
+ proto::assert_matches< proto::terminal< void(* const &)() > >( proto::as_child(&a_function) );
+ proto::assert_matches_not< proto::terminal< void(* const &)() > >( proto::as_expr(&a_function) );
+
+ proto::assert_matches<
+ proto::or_<
+ proto::if_<boost::is_same<proto::_value, char>() >
+ , proto::if_<boost::is_same<proto::_value, int>() >
>
- >( lit(1) );
+ >( proto::lit(1) );
 
- assert_matches_not<
- or_<
- if_<is_same<_value, char>() >
- , if_<is_same<_value, int>() >
+ proto::assert_matches_not<
+ proto::or_<
+ proto::if_<boost::is_same<proto::_value, char>() >
+ , proto::if_<boost::is_same<proto::_value, int>() >
>
- >( lit(1u) );
+ >( proto::lit(1u) );
 
- assert_matches< Input >( cin_ >> 1 >> 2 >> 3 );
- assert_matches_not< Output >( cin_ >> 1 >> 2 >> 3 );
+ proto::assert_matches< Input >( cin_ >> 1 >> 2 >> 3 );
+ proto::assert_matches_not< Output >( cin_ >> 1 >> 2 >> 3 );
 
- assert_matches< Output >( cout_ << 1 << 2 << 3 );
- assert_matches_not< Input >( cout_ << 1 << 2 << 3 );
+ proto::assert_matches< Output >( cout_ << 1 << 2 << 3 );
+ proto::assert_matches_not< Input >( cout_ << 1 << 2 << 3 );
 
- assert_matches< function< terminal<int>, vararg< terminal<char> > > >( lit(1)('a','b','c','d') );
- assert_matches_not< function< terminal<int>, vararg< terminal<char> > > >( lit(1)('a','b','c',"d") );
+ proto::assert_matches< proto::function< proto::terminal<int>, proto::vararg< proto::terminal<char> > > >( proto::lit(1)('a','b','c','d') );
+ proto::assert_matches_not< proto::function< proto::terminal<int>, proto::vararg< proto::terminal<char> > > >( proto::lit(1)('a','b','c',"d") );
 
- assert_matches< Anything >( cout_ << 1 << +lit('a') << lit(1)('a','b','c',"d") );
+ proto::assert_matches< Anything >( cout_ << 1 << +proto::lit('a') << proto::lit(1)('a','b','c',"d") );
 
- assert_matches< proto::switch_<MyCases> >( lit(1) >> 'a' );
- assert_matches< proto::switch_<MyCases> >( lit(1) + 'a' );
- assert_matches_not< proto::switch_<MyCases> >( lit(1) << 'a' );
+ proto::assert_matches< proto::switch_<MyCases> >( proto::lit(1) >> 'a' );
+ proto::assert_matches< proto::switch_<MyCases> >( proto::lit(1) + 'a' );
+ proto::assert_matches_not< proto::switch_<MyCases> >( proto::lit(1) << 'a' );
 
     number<int, two_complement_c> num;
- assert_matches<NumberGrammar>(proto::as_expr(num));
+ proto::assert_matches<NumberGrammar>(proto::as_expr(num));
 
     // check custom terminal types
     {
         proto::nullary_expr<my_terminal, int>::type i = {0};
 
- assert_matches<proto::nullary_expr<my_terminal, _> >( i );
- assert_matches_not<proto::terminal<_> >( i );
+ proto::assert_matches<proto::nullary_expr<my_terminal, proto::_> >( i );
+ proto::assert_matches_not<proto::terminal<proto::_> >( i );
 
         proto::terminal<int>::type j = {0};
- assert_matches<proto::terminal<_> >( j );
- assert_matches_not<proto::nullary_expr<my_terminal, _> >( j );
+ proto::assert_matches<proto::terminal<proto::_> >( j );
+ proto::assert_matches_not<proto::nullary_expr<my_terminal, proto::_> >( j );
 
- assert_matches<proto::nullary_expr<_, _> >( i );
+ proto::assert_matches<proto::nullary_expr<proto::_, proto::_> >( i );
     }
 
     // check 0 and 1 arg forms or or_ and and_
     {
- assert_matches< proto::and_<> >( lit(1) );
- assert_matches_not< proto::or_<> >( lit(1) );
+ proto::assert_matches< proto::and_<> >( proto::lit(1) );
+ proto::assert_matches_not< proto::or_<> >( proto::lit(1) );
 
- assert_matches< proto::and_<proto::terminal<int> > >( lit(1) );
- assert_matches< proto::or_<proto::terminal<int> > >( lit(1) );
+ proto::assert_matches< proto::and_<proto::terminal<int> > >( proto::lit(1) );
+ proto::assert_matches< proto::or_<proto::terminal<int> > >( proto::lit(1) );
     }
 
     // Test lambda matches with arrays, a corner case that had
     // a bug that was reported by Antoine de Maricourt on boost_at_[hidden]
     {
         a_template<int[3]> a;
- assert_matches< proto::terminal< a_template<_> > >( lit(a) );
+ proto::assert_matches< proto::terminal< a_template<proto::_> > >( proto::lit(a) );
     }
 
     // Test that the actual derived expression type makes it through to proto::if_
     {
         my_expr<proto::terminal<int>::type> e = {{1}};
- assert_matches< proto::if_<boost::is_same<domain_of<_>, my_domain>()> >( e );
+ proto::assert_matches< proto::if_<boost::is_same<proto::domain_of<proto::_>, my_domain>()> >( e );
     }
 }
 
-using namespace unit_test;
+using namespace boost::unit_test;
 ///////////////////////////////////////////////////////////////////////////////
 // init_unit_test_suite
 //

Modified: branches/release/libs/proto/test/switch.cpp
==============================================================================
--- branches/release/libs/proto/test/switch.cpp (original)
+++ branches/release/libs/proto/test/switch.cpp 2011-10-13 02:33:10 EDT (Thu, 13 Oct 2011)
@@ -15,8 +15,7 @@
 #include <boost/mpl/long.hpp>
 #include <boost/mpl/bool.hpp>
 
-using namespace boost;
-using namespace proto;
+namespace proto = boost::proto;
 
 struct MyCases
 {
@@ -41,7 +40,7 @@
 struct ArityOfCases
 {
     template<typename ArityOf>
- struct case_
+ struct case_
       : proto::not_<proto::_>
     {};
 };
@@ -49,7 +48,7 @@
 
 template<>
 struct ArityOfCases::case_<boost::mpl::long_<1> >
-: boost::proto::when<boost::proto::_, boost::mpl::false_()>
+ : boost::proto::when<boost::proto::_, boost::mpl::false_()>
 {};
 
 template<>
@@ -67,21 +66,21 @@
 void test_switch()
 {
     // Tests for backward compatibility
- assert_matches<proto::switch_<MyCases> >(lit(1) >> 'a');
- assert_matches<proto::switch_<MyCases> >(lit(1) + 'a');
- assert_matches_not<proto::switch_<MyCases> >(lit(1) << 'a');
+ proto::assert_matches<proto::switch_<MyCases> >(proto::lit(1) >> 'a');
+ proto::assert_matches<proto::switch_<MyCases> >(proto::lit(1) + 'a');
+ proto::assert_matches_not<proto::switch_<MyCases> >(proto::lit(1) << 'a');
 
     //Test new matching on the Transform result type
     ArityOf ar;
 
- assert_matches_not<ArityOf>(lit(1));
- assert_matches<ArityOf>(lit(1) + 2);
- assert_matches<ArityOf>(!lit(1));
- BOOST_CHECK_EQUAL(ar(!lit(1)), false);
- BOOST_CHECK_EQUAL(ar(lit(1) + 2), true);
+ proto::assert_matches_not<ArityOf>(proto::lit(1));
+ proto::assert_matches<ArityOf>(proto::lit(1) + 2);
+ proto::assert_matches<ArityOf>(!proto::lit(1));
+ BOOST_CHECK_EQUAL(ar(!proto::lit(1)), false);
+ BOOST_CHECK_EQUAL(ar(proto::lit(1) + 2), true);
 }
 
-using namespace unit_test;
+using namespace boost::unit_test;
 ///////////////////////////////////////////////////////////////////////////////
 // init_unit_test_suite
 //


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