Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r70736 - in sandbox/assign_v2: boost/assign/v2 boost/assign/v2/option boost/assign/v2/pipe libs/assign/v2/test/unit_testing
From: erwann.rogard_at_[hidden]
Date: 2011-03-29 21:53:48


Author: e_r
Date: 2011-03-29 21:53:47 EDT (Tue, 29 Mar 2011)
New Revision: 70736
URL: http://svn.boost.org/trac/boost/changeset/70736

Log:
upd assign_v2
Text files modified:
   sandbox/assign_v2/boost/assign/v2/option/list.hpp | 66 ++++++++++----------
   sandbox/assign_v2/boost/assign/v2/pipe/csv_put.hpp | 124 ++++++++++++++++++++--------------------
   sandbox/assign_v2/boost/assign/v2/put.hpp | 44 +++++++-------
   sandbox/assign_v2/libs/assign/v2/test/unit_testing/option.cpp | 3
   4 files changed, 118 insertions(+), 119 deletions(-)

Modified: sandbox/assign_v2/boost/assign/v2/option/list.hpp
==============================================================================
--- sandbox/assign_v2/boost/assign/v2/option/list.hpp (original)
+++ sandbox/assign_v2/boost/assign/v2/option/list.hpp 2011-03-29 21:53:47 EDT (Tue, 29 Mar 2011)
@@ -32,89 +32,89 @@
         #ifdef BOOST_MSVC
         BOOST_TYPEOF_NESTED_TYPEDEF_TPL(nested, lhs % option )
         typedef typename nested::type type;
- #else
+ #else
         typedef BOOST_TYPEOF_TPL( lhs % option ) type;
- #endif
+ #endif
     };
 
- template<typename Head>
+ template<typename Head>
     struct option_list_exit
- : boost::is_same<Head, keyword_aux::nil>
+ : boost::is_same<Head, keyword_aux::nil>
     {};
 
 namespace result_of{
 
     template<
- typename Head,
+ typename Head,
         typename Tail,
         typename Lhs,
         bool exit = option_list_exit<Head>::value
>
     struct apply_list_option
     {
- typedef typename apply_list_option<
- typename Tail::head_type, typename Tail::tail_type, Lhs
+ typedef typename apply_list_option<
+ typename Tail::head_type, typename Tail::tail_type, Lhs
>::type lhs_;
         
         typedef typename modulo_result<lhs_, Head>::type type;
     };
 
     template<
- typename Head,
+ typename Head,
         typename Tail,
         typename Lhs
>
     struct apply_list_option<Head, Tail, Lhs, true>
     {
- typedef Lhs type;
+ typedef Lhs type;
     };
     
 }// result_of
     
- template<
- typename Head = keyword_aux::nil,
- typename Tail = boost::mpl::empty_base,
+ template<
+ typename Head = keyword_aux::nil,
+ typename Tail = boost::mpl::empty_base,
         bool exit = option_list_exit<Head>::value
>
     struct list_option : public Tail
     {
 
- typedef Head head_type;
+ typedef Head head_type;
         typedef Tail tail_type;
 
- list_option(){ /*exit = true*/ }
- list_option(Tail tail, Head h)
- : Tail( tail ), head_( h )
- {}
+ list_option(){ /*exit = true*/ }
+ list_option(Tail tail, Head h)
+ : Tail( tail ), head_( h )
+ {}
     
- template<typename Option>
+ template<typename Option>
         struct result
         {
- typedef list_option<Option, list_option> type;
+ typedef list_option<Option, list_option> type;
         };
     
- template<typename Option>
+ template<typename Option>
         typename result<Option>::type
- operator%(Option option)const
+ operator%(Option option)const
         {
- typedef typename result<Option>::type result_;
+ typedef typename result<Option>::type result_;
             return result_( *this, option );
         }
                         
         template<typename Lhs>
         typename boost::lazy_disable_if_c<
- exit, result_of::apply_list_option<Head, Tail, Lhs>
+ exit, result_of::apply_list_option<Head, Tail, Lhs>
>::type
         apply(Lhs const& lhs)const
         {
- return static_cast<
- Tail const&
+ return static_cast<
+ Tail const&
>( *this ).apply( lhs ) % this->head_;
         }
 
         template<typename Lhs>
         typename boost::lazy_enable_if_c<
- exit, result_of::apply_list_option<Head, Tail, Lhs>
+ exit, result_of::apply_list_option<Head, Tail, Lhs>
>::type
         apply(Lhs const& lhs)const{ return lhs; }
         
@@ -123,11 +123,11 @@
     
     };
 
- typedef list_option<> empty_list_option;
+ typedef list_option<> empty_list_option;
 
     template<
- typename C, typename F, typename ModifierTag,
- typename DataTag, typename D,
+ typename C, typename F, typename ModifierTag,
+ typename DataTag, typename D,
         typename H, typename T
>
     typename result_of::apply_list_option<H, T, D>::type
@@ -136,13 +136,13 @@
         list_option<H, T> const& list
     )
     {
- return list.apply( lhs );
- }
+ return list.apply( lhs );
+ }
     
 }// interpreter_aux
 namespace{
- interpreter_aux::empty_list_option _list_option
- = interpreter_aux::empty_list_option();
+ interpreter_aux::empty_list_option _list_option
+ = interpreter_aux::empty_list_option();
 }
 }// v2
 }// assign

Modified: sandbox/assign_v2/boost/assign/v2/pipe/csv_put.hpp
==============================================================================
--- sandbox/assign_v2/boost/assign/v2/pipe/csv_put.hpp (original)
+++ sandbox/assign_v2/boost/assign/v2/pipe/csv_put.hpp 2011-03-29 21:53:47 EDT (Tue, 29 Mar 2011)
@@ -59,14 +59,14 @@
     }/*->*/;
 
     template<
- typename Head/*<-*/ = typename empty_list_option::head_type/*->*/,
+ typename Head/*<-*/ = typename empty_list_option::head_type/*->*/,
         typename Tail/*<-*/ = typename empty_list_option::tail_type/*->*/
>
     class arg_list_generator : public list_option<Head, Tail>/*<-*/
     {
 
         typedef ::boost::mpl::na na_;
- typedef list_option<Head, Tail> list_option_;
+ typedef list_option<Head, Tail> list_option_;
 
         public:
 
@@ -75,17 +75,17 @@
             : list_option_( t, h )
         {}
 
- template<typename Option>
+ template<typename Option>
         struct modulo_result
         {
- typedef arg_list_generator<Option, arg_list_generator> type;
+ typedef arg_list_generator<Option, arg_list_generator> type;
         };
     
- template<typename Option>
+ template<typename Option>
         typename modulo_result<Option>::type
- operator%(Option option)const
+ operator%(Option option)const
         {
- typedef typename modulo_result<Option>::type result_;
+ typedef typename modulo_result<Option>::type result_;
             return result_( *this, option );
         }
 
@@ -96,34 +96,34 @@
  
 #if BOOST_ASSIGN_V2_ENABLE_CPP0X
 
- protected:
- template<typename T, typename...Args>
- typename result<sizeof...(Args) + 1, T>::type
- impl(T& t, Args&...args)const
- {
- typedef typename result<sizeof...(Args)+1, T>::type result_;
- namespace ns = ref::assign_copy;
- return result_(*this, ref::csv_array( t, args... ) );
- }
-
- public:
-
- template<typename T, typename...Args>
- typename boost::lazy_disable_if<
- v2::type_traits::or_const<T, Args...>,
- result<sizeof...(Args)+1, T>
- >::type
- operator()(T& t, Args&...args)const
- {
- return this->impl(t, args...);
- }
-
- template<typename T, typename...Args>
- typename result<sizeof...(Args)+1, T const>::type
- operator()(T const& t, Args const&...args)const
- {
- return this->impl(t, args...);
- }
+ protected:
+ template<typename T, typename...Args>
+ typename result<sizeof...(Args) + 1, T>::type
+ impl(T& t, Args&...args)const
+ {
+ typedef typename result<sizeof...(Args)+1, T>::type result_;
+ namespace ns = ref::assign_copy;
+ return result_(*this, ref::csv_array( t, args... ) );
+ }
+
+ public:
+
+ template<typename T, typename...Args>
+ typename boost::lazy_disable_if<
+ v2::type_traits::or_const<T, Args...>,
+ result<sizeof...(Args)+1, T>
+ >::type
+ operator()(T& t, Args&...args)const
+ {
+ return this->impl(t, args...);
+ }
+
+ template<typename T, typename...Args>
+ typename result<sizeof...(Args)+1, T const>::type
+ operator()(T const& t, Args const&...args)const
+ {
+ return this->impl(t, args...);
+ }
 
 #else
 
@@ -138,26 +138,26 @@
         }
 
 #define BOOST_ASSIGN_V2_MACRO1(N, U)\
- return result_( \
- *this, \
- ref::csv_array<U>( BOOST_PP_ENUM_PARAMS(N, _) ) \
- );\
+ return result_( \
+ *this, \
+ ref::csv_array<U>( BOOST_PP_ENUM_PARAMS(N, _) ) \
+ );\
 /**/
 #define BOOST_ASSIGN_V2_MACRO2(z, N, data)\
- template<typename T>\
- typename result<N, T>::type\
- operator()( BOOST_PP_ENUM_PARAMS(N, T &_) )const \
- { \
- typedef typename result<N, T>::type result_;\
- BOOST_ASSIGN_V2_MACRO1( N, T )\
- } \
- template<typename T>\
- typename result<N, T const>::type\
- operator()( BOOST_PP_ENUM_PARAMS(N, T const &_) )const \
- { \
- typedef typename result<N, T const>::type result_;\
- BOOST_ASSIGN_V2_MACRO1( N, T const )\
- } \
+ template<typename T>\
+ typename result<N, T>::type\
+ operator()( BOOST_PP_ENUM_PARAMS(N, T &_) )const \
+ { \
+ typedef typename result<N, T>::type result_;\
+ BOOST_ASSIGN_V2_MACRO1( N, T )\
+ } \
+ template<typename T>\
+ typename result<N, T const>::type\
+ operator()( BOOST_PP_ENUM_PARAMS(N, T const &_) )const \
+ { \
+ typedef typename result<N, T const>::type result_;\
+ BOOST_ASSIGN_V2_MACRO1( N, T const )\
+ } \
 /**/
 
 BOOST_PP_REPEAT_FROM_TO(
@@ -174,19 +174,19 @@
     }/*->*/;
 
     template<
- typename C, typename H, typename T,
+ typename C, typename H, typename T,
         arg_list_size_type N, typename U
>
     C& operator|(C& cont, interpreter_aux::arg_list<H, T, N, U> const& arg_list)/*<-*/
     {
- typedef typename v2::result_of::put<
- C
- , functor_aux::value<
- typename container_aux::value<C>::type
- >
- , typename interpreter_aux::deduce_modifier_tag<C>::type
- , typename interpreter_aux::deduce_data_tag<C>::type
- >::type put_;
+ typedef typename v2::result_of::put<
+ C
+ , functor_aux::value<
+ typename container_aux::value<C>::type
+ >
+ , typename interpreter_aux::deduce_modifier_tag<C>::type
+ , typename interpreter_aux::deduce_data_tag<C>::type
+ >::type put_;
         v2::ref::as_arg_list(
             arg_list.apply( put_( cont ) ),
             arg_list.arg_list_cont()

Modified: sandbox/assign_v2/boost/assign/v2/put.hpp
==============================================================================
--- sandbox/assign_v2/boost/assign/v2/put.hpp (original)
+++ sandbox/assign_v2/boost/assign/v2/put.hpp 2011-03-29 21:53:47 EDT (Tue, 29 Mar 2011)
@@ -28,20 +28,20 @@
         protected ref::wrapper< ref::assign_tag::copy, C >,
 //->
         public interpreter_aux::interpreter_crtp<
- C,
+ C,
             F,
             ModifierTag, DataTag, put_interpreter<C, F, ModifierTag, DataTag>
>
     {
 //<-
         typedef interpreter_aux::interpreter_crtp<
- C, F, ModifierTag, DataTag, put_interpreter
+ C, F, ModifierTag, DataTag, put_interpreter
> super2_t;
 //->
         public:
 
         typedef /*<-*/ typename super2_t::result_type
- BOOST_ASSIGN_V2_IGNORE(/*->*/ unspecified /*<-*/)/*->*/
+ BOOST_ASSIGN_V2_IGNORE(/*->*/ unspecified /*<-*/)/*->*/
         result_type;
 //<-
         protected:
@@ -69,36 +69,36 @@
 
     template<typename C, typename F, typename ModifierTag, typename DataTag>
     struct replace_data_generator<
- interpreter_aux::put_interpreter<C, F, ModifierTag, DataTag>
+ interpreter_aux::put_interpreter<C, F, ModifierTag, DataTag>
>{
         template<typename F1>
         struct apply/*<-*/{
- typedef interpreter_aux::put_interpreter<
- C, F1, ModifierTag, DataTag
+ typedef interpreter_aux::put_interpreter<
+ C, F1, ModifierTag, DataTag
> type;
         }/*->*/;
     };
 
     template<typename C, typename F, typename ModifierTag, typename DataTag>
     struct replace_modifier_tag<
- interpreter_aux::put_interpreter<C, F, ModifierTag, DataTag>
+ interpreter_aux::put_interpreter<C, F, ModifierTag, DataTag>
>{
         template<typename ModifierTag1>
         struct apply/*<-*/{
- typedef interpreter_aux::put_interpreter<
- C, F, ModifierTag1, DataTag
+ typedef interpreter_aux::put_interpreter<
+ C, F, ModifierTag1, DataTag
> type;
         }/*->*/;
     };
 
     template<typename C, typename F, typename ModifierTag, typename DataTag>
     struct replace_data_tag<
- interpreter_aux::put_interpreter<C, F, ModifierTag, DataTag>
+ interpreter_aux::put_interpreter<C, F, ModifierTag, DataTag>
>{
         template<typename DataTag1>
         struct apply/*<-*/{
- typedef interpreter_aux::put_interpreter<
- C, F, ModifierTag, DataTag1
+ typedef interpreter_aux::put_interpreter<
+ C, F, ModifierTag, DataTag1
> type;
         }/*->*/;
     };
@@ -107,18 +107,18 @@
 namespace result_of{
 
     template<
- typename C/*<-*/
- , typename DataGenerator
- = typename interpreter_aux::deduce_data_generator<C>::type
+ typename C/*<-*/
+ , typename DataGenerator
+ = typename interpreter_aux::deduce_data_generator<C>::type
         , typename ModifierTag
- = typename interpreter_aux::deduce_modifier_tag<C>::type
+ = typename interpreter_aux::deduce_modifier_tag<C>::type
         , typename DataTag
- = typename interpreter_aux::deduce_data_tag<C>::type/*->*/
+ = typename interpreter_aux::deduce_data_tag<C>::type/*->*/
>
     struct put/*<-*/{
         typedef
- interpreter_aux::put_interpreter<
- C,
+ interpreter_aux::put_interpreter<
+ C,
                 DataGenerator,
                 ModifierTag,
                 DataTag
@@ -138,7 +138,7 @@
 
 /*<-*/
     template<
- typename DataGenerator
+ typename DataGenerator
         ,typename ModifierTag
         ,typename DataTag
         ,typename C
@@ -146,8 +146,8 @@
     typename result_of::put<C, DataGenerator, ModifierTag, DataTag>::type
     put( C& cont )
     {
- typedef typename result_of::put<
- C, DataGenerator, ModifierTag, DataTag
+ typedef typename result_of::put<
+ C, DataGenerator, ModifierTag, DataTag
>::type result_;
         return result_( cont );
     }

Modified: sandbox/assign_v2/libs/assign/v2/test/unit_testing/option.cpp
==============================================================================
--- sandbox/assign_v2/libs/assign/v2/test/unit_testing/option.cpp (original)
+++ sandbox/assign_v2/libs/assign/v2/test/unit_testing/option.cpp 2011-03-29 21:53:47 EDT (Tue, 29 Mar 2011)
@@ -19,8 +19,7 @@
 #include <libs/assign/v2/test/option/mapped.cpp>
 #include <libs/assign/v2/test/option/repeat.cpp>
 #include <libs/assign/v2/test/option/std_modifier.cpp>
-
-
+
 #include <boost/test/unit_test.hpp>
 using boost::unit_test::test_suite;
 test_suite* init_unit_test_suite( int argc, char* argv[] )


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