Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r67471 - in branches/release: . boost boost/algorithm/string boost/archive boost/bimap boost/config boost/detail boost/filesystem boost/functional/hash boost/fusion boost/gil boost/graph boost/icl boost/integer boost/interprocess boost/intrusive boost/io boost/iostreams boost/math boost/msm boost/numeric/ublas boost/program_options boost/property_tree boost/proto boost/proto/functional boost/proto/functional/fusion boost/proto/transform boost/python 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/type_traits boost/typeof boost/unordered boost/utility boost/uuid boost/variant boost/wave doc libs libs/algorithm/string libs/array/doc libs/array/test libs/bimap libs/config libs/date_time libs/filesystem libs/functional/hash libs/fusion libs/graph_parallel libs/icl libs/integer libs/interprocess libs/intrusive libs/iostreams libs/math libs/math/doc libs/math/doc/sf_and_dist libs/mpi/build libs/mpl/doc/refmanual libs/mpl/doc/src/refmanual libs/msm libs/numeric/ublas libs/numeric/ublas/doc libs/program_options libs/property_tree libs/proto/doc libs/proto/doc/reference/functional/fusion libs/proto/example libs/python libs/range libs/regex libs/serialization libs/serialization/doc libs/serialization/example libs/serialization/src libs/serialization/test libs/serialization/vc7ide libs/signals libs/signals2 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/type_traits libs/type_traits/doc libs/typeof/doc libs/unordered libs/utility libs/utility/swap/test libs/uuid libs/wave more more/getting_started status tools tools/bcp tools/boostbook tools/build/v2 tools/inspect tools/quickbook tools/regression tools/regression/src tools/release tools/wave
From: eric_at_[hidden]
Date: 2010-12-27 16:22:56


Author: eric_niebler
Date: 2010-12-27 16:22:55 EST (Mon, 27 Dec 2010)
New Revision: 67471
URL: http://svn.boost.org/trac/boost/changeset/67471

Log:
merge [67464], [67465], and [67470] from trunk
Added:
   branches/release/boost/proto/functional/fusion/at.hpp
      - copied unchanged from r67465, /trunk/boost/proto/functional/fusion/at.hpp
   branches/release/libs/proto/doc/reference/functional/fusion/at.xml
      - copied unchanged from r67465, /trunk/libs/proto/doc/reference/functional/fusion/at.xml
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/config/ (props changed)
   branches/release/boost/config.hpp (props changed)
   branches/release/boost/detail/ (props changed)
   branches/release/boost/detail/endian.hpp (props changed)
   branches/release/boost/filesystem/ (props changed)
   branches/release/boost/filesystem.hpp (props changed)
   branches/release/boost/functional/hash/ (props changed)
   branches/release/boost/fusion/ (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/interprocess/ (props changed)
   branches/release/boost/intrusive/ (props changed)
   branches/release/boost/io/ (props changed)
   branches/release/boost/iostreams/ (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/numeric/ublas/ (props changed)
   branches/release/boost/numeric/ublas/functional.hpp (props changed)
   branches/release/boost/program_options/ (props changed)
   branches/release/boost/property_tree/ (props changed)
   branches/release/boost/python/ (props changed)
   branches/release/boost/range/ (props changed)
   branches/release/boost/regex/ (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/system/ (props changed)
   branches/release/boost/thread/ (props changed)
   branches/release/boost/thread.hpp (props changed)
   branches/release/boost/token_functions.hpp (props changed)
   branches/release/boost/tr1/ (props changed)
   branches/release/boost/type_traits/ (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/unordered/ (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/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/doc/array.xml (props changed)
   branches/release/libs/array/test/array0.cpp (props changed)
   branches/release/libs/array/test/array2.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/filesystem/ (props changed)
   branches/release/libs/functional/hash/ (props changed)
   branches/release/libs/fusion/ (props changed)
   branches/release/libs/graph_parallel/ (props changed)
   branches/release/libs/icl/ (props changed)
   branches/release/libs/integer/ (props changed)
   branches/release/libs/interprocess/ (props changed)
   branches/release/libs/intrusive/ (props changed)
   branches/release/libs/iostreams/ (props changed)
   branches/release/libs/libraries.htm (props changed)
   branches/release/libs/maintainers.txt (props changed)
   branches/release/libs/math/ (props changed)
   branches/release/libs/math/doc/ (props changed)
   branches/release/libs/math/doc/sf_and_dist/ (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/program_options/ (props changed)
   branches/release/libs/property_tree/ (props changed)
   branches/release/libs/python/ (props changed)
   branches/release/libs/range/ (props changed)
   branches/release/libs/regex/ (props changed)
   branches/release/libs/serialization/ (props changed)
   branches/release/libs/serialization/doc/ (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/serialization/vc7ide/ (props changed)
   branches/release/libs/signals/ (props changed)
   branches/release/libs/signals2/ (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/type_traits/ (props changed)
   branches/release/libs/type_traits/doc/ (props changed)
   branches/release/libs/typeof/doc/typeof.qbk (props changed)
   branches/release/libs/unordered/ (props changed)
   branches/release/libs/utility/ (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/more/getting_started/ (props changed)
   branches/release/rst.css (props changed)
   branches/release/status/ (props changed)
   branches/release/status/Jamfile.v2 (props changed)
   branches/release/status/explicit-failures-markup.xml (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/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/functional/fusion.hpp | 1
   branches/release/boost/proto/proto_fwd.hpp | 2
   branches/release/boost/proto/transform/make.hpp | 108 +++++++--------------------------------
   branches/release/libs/proto/doc/reference.xml | 6 ++
   branches/release/libs/proto/example/calc1.cpp | 2
   branches/release/libs/proto/example/calc2.cpp | 2
   6 files changed, 30 insertions(+), 91 deletions(-)

Modified: branches/release/boost/proto/functional/fusion.hpp
==============================================================================
--- branches/release/boost/proto/functional/fusion.hpp (original)
+++ branches/release/boost/proto/functional/fusion.hpp 2010-12-27 16:22:55 EST (Mon, 27 Dec 2010)
@@ -9,6 +9,7 @@
 #ifndef BOOST_PROTO_FUNCTIONAL_FUSION_HPP_EAN_11_27_2010
 #define BOOST_PROTO_FUNCTIONAL_FUSION_HPP_EAN_11_27_2010
 
+#include <boost/proto/functional/fusion/at.hpp>
 #include <boost/proto/functional/fusion/pop_back.hpp>
 #include <boost/proto/functional/fusion/pop_front.hpp>
 #include <boost/proto/functional/fusion/push_back.hpp>

Modified: branches/release/boost/proto/proto_fwd.hpp
==============================================================================
--- branches/release/boost/proto/proto_fwd.hpp (original)
+++ branches/release/boost/proto/proto_fwd.hpp 2010-12-27 16:22:55 EST (Mon, 27 Dec 2010)
@@ -584,6 +584,7 @@
         struct make_pair;
         struct first;
         struct second;
+ struct at;
         struct pop_front;
         struct push_front;
         struct pop_back;
@@ -595,6 +596,7 @@
     typedef functional::make_pair _make_pair;
     typedef functional::first _first;
     typedef functional::second _second;
+ typedef functional::pop_front _at;
     typedef functional::pop_front _pop_front;
     typedef functional::push_front _push_front;
     typedef functional::pop_back _pop_back;

Modified: branches/release/boost/proto/transform/make.hpp
==============================================================================
--- branches/release/boost/proto/transform/make.hpp (original)
+++ branches/release/boost/proto/transform/make.hpp 2010-12-27 16:22:55 EST (Mon, 27 Dec 2010)
@@ -22,6 +22,7 @@
     #include <boost/preprocessor/iteration/iterate.hpp>
     #include <boost/preprocessor/selection/max.hpp>
     #include <boost/preprocessor/arithmetic/inc.hpp>
+ #include <boost/mpl/and.hpp>
     #include <boost/mpl/aux_/has_type.hpp>
     #include <boost/mpl/aux_/template_arity.hpp>
     #include <boost/mpl/aux_/lambda_arity_param.hpp>
@@ -37,34 +38,9 @@
     {
         namespace detail
         {
- enum callable_type
- {
- CT_not_callable
- , CT_callable
- , CT_transform
- };
-
- template<typename T, bool IsTransform = is_transform<T>::value>
- struct get_callable_type2
- {
- static callable_type const value = CT_callable;
- };
-
             template<typename T>
- struct get_callable_type2<T, true>
- {
- static callable_type const value = CT_transform;
- };
-
- template<typename T, bool IsCallable = is_callable<T>::value>
- struct get_callable_type
- {
- static callable_type const value = CT_not_callable;
- };
-
- template<typename T>
- struct get_callable_type<T, true>
- : get_callable_type2<T>
+ struct is_applyable
+ : mpl::and_<is_callable<T>, is_transform<T> >
             {};
 
             template<typename T, bool HasType = mpl::aux::has_type<T>::value>
@@ -79,19 +55,15 @@
                 typedef T type;
             };
 
- template<
- typename T
- , typename Expr, typename State, typename Data
- , bool Applied
- >
+ template<typename T, bool Applied>
             struct nested_type_if
             {
                 typedef T type;
                 static bool const applied = false;
             };
 
- template<typename T, typename Expr, typename State, typename Data>
- struct nested_type_if<T, Expr, State, Data, true>
+ template<typename T>
+ struct nested_type_if<T, true>
               : nested_type<T>
             {
                 static bool const applied = true;
@@ -111,31 +83,23 @@
             template<
                 typename R
               , typename Expr, typename State, typename Data
- , callable_type CallableType = get_callable_type<R>::value
+ , bool IsApplyable = is_applyable<R>::value
>
- struct make_if_;
-
- template<typename R, typename Expr, typename State, typename Data>
- struct make_if_<R, Expr, State, Data, CT_callable>
+ struct make_if_
               : make_<R, Expr, State, Data>
             {};
 
             template<typename R, typename Expr, typename State, typename Data>
- struct make_if_<R, Expr, State, Data, CT_transform>
- : uncvref<typename R::template impl<Expr, State, Data>::result_type>
+ struct make_if_<R, Expr, State, Data, true>
+ : uncvref<typename when<_, R>::template impl<Expr, State, Data>::result_type>
             {
                 static bool const applied = true;
             };
 
- template<typename R, typename Expr, typename State, typename Data>
- struct make_if_<R, Expr, State, Data, CT_not_callable>
- : make_<R, Expr, State, Data>
- {};
-
             #if BOOST_WORKAROUND(__GNUC__, == 3) || (__GNUC__ == 4 && __GNUC_MINOR__ == 0)
             // work around GCC bug
             template<typename Tag, typename Args, long N, typename Expr, typename State, typename Data>
- struct make_if_<proto::expr<Tag, Args, N>, Expr, State, Data, CT_not_callable>
+ struct make_if_<proto::expr<Tag, Args, N>, Expr, State, Data, false>
             {
                 typedef proto::expr<Tag, Args, N> type;
                 static bool const applied = false;
@@ -143,7 +107,7 @@
 
             // work around GCC bug
             template<typename Tag, typename Args, long N, typename Expr, typename State, typename Data>
- struct make_if_<proto::basic_expr<Tag, Args, N>, Expr, State, Data, CT_not_callable>
+ struct make_if_<proto::basic_expr<Tag, Args, N>, Expr, State, Data, false>
             {
                 typedef proto::basic_expr<Tag, Args, N> type;
                 static bool const applied = false;
@@ -343,11 +307,7 @@
               , Expr, State, Data
                 BOOST_MPL_AUX_LAMBDA_ARITY_PARAM(N)
>
- : nested_type_if<
- R<BOOST_PP_ENUM(N, TMP1, ~)>
- , Expr, State, Data
- , (BOOST_PP_REPEAT(N, TMP2, ~) false)
- >
+ : nested_type_if<R<BOOST_PP_ENUM(N, TMP1, ~)>, (BOOST_PP_REPEAT(N, TMP2, ~) false)>
             {};
 
             template<
@@ -370,41 +330,15 @@
             #undef TMP2
             #endif
 
- template<
- typename R
- BOOST_PP_ENUM_TRAILING_PARAMS(N, typename A)
- , typename Expr, typename State, typename Data
- >
- struct make_if_<
- R(BOOST_PP_ENUM_PARAMS(N, A))
- , Expr, State, Data
- , CT_not_callable
- >
- : uncvref<
- typename when<_, R(BOOST_PP_ENUM_PARAMS(N, A))>
- ::template impl<Expr, State, Data>::result_type
- >
- {
- static bool const applied = true;
- };
+ template<typename R BOOST_PP_ENUM_TRAILING_PARAMS(N, typename A)>
+ struct is_applyable<R(BOOST_PP_ENUM_PARAMS(N, A))>
+ : mpl::true_
+ {};
 
- template<
- typename R
- BOOST_PP_ENUM_TRAILING_PARAMS(N, typename A)
- , typename Expr, typename State, typename Data
- >
- struct make_if_<
- R(*)(BOOST_PP_ENUM_PARAMS(N, A))
- , Expr, State, Data
- , CT_not_callable
- >
- : uncvref<
- typename when<_, R(BOOST_PP_ENUM_PARAMS(N, A))>
- ::template impl<Expr, State, Data>::result_type
- >
- {
- static bool const applied = true;
- };
+ template<typename R BOOST_PP_ENUM_TRAILING_PARAMS(N, typename A)>
+ struct is_applyable<R(*)(BOOST_PP_ENUM_PARAMS(N, A))>
+ : mpl::true_
+ {};
 
             template<typename T, typename A>
             struct construct_<proto::expr<T, A, N>, true>

Modified: branches/release/libs/proto/doc/reference.xml
==============================================================================
--- branches/release/libs/proto/doc/reference.xml (original)
+++ branches/release/libs/proto/doc/reference.xml 2010-12-27 16:22:55 EST (Mon, 27 Dec 2010)
@@ -292,6 +292,11 @@
       </listitem>
       <listitem>
         <computeroutput>
+ <classname alt="boost::proto::functional::at">proto::functional::at</classname>
+ </computeroutput>
+ </listitem>
+ <listitem>
+ <computeroutput>
           <classname alt="boost::proto::functional::child">proto::functional::child</classname>
         </computeroutput>
       </listitem>
@@ -1105,6 +1110,7 @@
   <xi:include href="reference/extends.xml"/>
   <xi:include href="reference/functional.xml"/>
   <xi:include href="reference/functional/fusion.xml"/>
+ <xi:include href="reference/functional/fusion/at.xml"/>
   <xi:include href="reference/functional/fusion/pop_back.xml"/>
   <xi:include href="reference/functional/fusion/pop_front.xml"/>
   <xi:include href="reference/functional/fusion/push_back.xml"/>

Modified: branches/release/libs/proto/example/calc1.cpp
==============================================================================
--- branches/release/libs/proto/example/calc1.cpp (original)
+++ branches/release/libs/proto/example/calc1.cpp 2010-12-27 16:22:55 EST (Mon, 27 Dec 2010)
@@ -7,10 +7,8 @@
 // evaluator with placeholders.
 
 #include <iostream>
-#include <boost/mpl/int.hpp>
 #include <boost/proto/core.hpp>
 #include <boost/proto/context.hpp>
-namespace mpl = boost::mpl;
 namespace proto = boost::proto;
 using proto::_;
 

Modified: branches/release/libs/proto/example/calc2.cpp
==============================================================================
--- branches/release/libs/proto/example/calc2.cpp (original)
+++ branches/release/libs/proto/example/calc2.cpp 2010-12-27 16:22:55 EST (Mon, 27 Dec 2010)
@@ -9,10 +9,8 @@
 // function object
 
 #include <iostream>
-#include <boost/mpl/int.hpp>
 #include <boost/proto/core.hpp>
 #include <boost/proto/context.hpp>
-namespace mpl = boost::mpl;
 namespace proto = boost::proto;
 using proto::_;
 


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