Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r74511 - trunk/libs/proto/example
From: eric_at_[hidden]
Date: 2011-09-22 12:05:59


Author: eric_niebler
Date: 2011-09-22 12:05:58 EDT (Thu, 22 Sep 2011)
New Revision: 74511
URL: http://svn.boost.org/trac/boost/changeset/74511

Log:
misc clean-up
Text files modified:
   trunk/libs/proto/example/lambda.hpp | 7 +++----
   trunk/libs/proto/example/map_assign.cpp | 2 ++
   trunk/libs/proto/example/virtual_member.cpp | 2 +-
   3 files changed, 6 insertions(+), 5 deletions(-)

Modified: trunk/libs/proto/example/lambda.hpp
==============================================================================
--- trunk/libs/proto/example/lambda.hpp (original)
+++ trunk/libs/proto/example/lambda.hpp 2011-09-22 12:05:58 EDT (Thu, 22 Sep 2011)
@@ -2,7 +2,6 @@
     #ifndef BOOST_LAMBDA_HPP_EAN_04_19_2008
     #define BOOST_LAMBDA_HPP_EAN_04_19_2008
 
- #define BOOST_MPL_LIMIT_METAFUNCTION_ARITY 10
     #define BOOST_PROTO_MAX_ARITY 10
     #define BOOST_PROTO_MAX_FUNCTION_CALL_ARITY 5
 
@@ -57,7 +56,7 @@
             struct rethrow_ {};
             struct switch_ {};
             struct default_ {};
- template<int I> struct case_ { BOOST_STATIC_CONSTANT(int, value = I); };
+ template<int I> struct case_ { static const int value = I; };
             template<typename E> struct catch_ { typedef E exception_type; };
             struct catch_all_ { typedef catch_all_ exception_type; };
         };
@@ -70,7 +69,7 @@
             typedef placeholder<Int> type;
             typedef placeholder<typename Int::next> next;
             typedef placeholder<typename Int::prior> prior;
- BOOST_STATIC_CONSTANT(value_type, value = Int::value);
+ static const value_type value = Int::value;
 
             friend std::ostream &operator<<(std::ostream &sout, placeholder)
             {
@@ -505,7 +504,7 @@
             static yes_type test_is_stream(std::basic_ostream<Char, Traits> &);
         public:
             typedef bool value_type;
- BOOST_STATIC_CONSTANT(bool, value = sizeof(yes_type) == sizeof(test_is_stream(t)));
+ static const bool value = sizeof(yes_type == sizeof(test_is_stream(t)));
             typedef mpl::bool_<value> type;
         };
 

Modified: trunk/libs/proto/example/map_assign.cpp
==============================================================================
--- trunk/libs/proto/example/map_assign.cpp (original)
+++ trunk/libs/proto/example/map_assign.cpp 2011-09-22 12:05:58 EDT (Thu, 22 Sep 2011)
@@ -51,6 +51,7 @@
 struct MapListOf
   : proto::or_<
         proto::when<
+ // map_list_of(a,b)
             proto::function<
                 proto::terminal<map_list_of_tag>
               , proto::terminal<_>
@@ -63,6 +64,7 @@
             )
>
       , proto::when<
+ // map_list_of(a,b)(c,d)...
             proto::function<
                 MapListOf
               , proto::terminal<_>

Modified: trunk/libs/proto/example/virtual_member.cpp
==============================================================================
--- trunk/libs/proto/example/virtual_member.cpp (original)
+++ trunk/libs/proto/example/virtual_member.cpp 2011-09-22 12:05:58 EDT (Thu, 22 Sep 2011)
@@ -72,7 +72,7 @@
         typedef typename N::next next;
         typedef typename N::prior prior;
         typedef typename N::value_type value_type;
- BOOST_STATIC_CONSTANT(value_type, value = N::value);
+ static const value_type value = N::value;
     };
 
     // Some keyword types for our lambda DSEL


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