Boost logo

Boost-Commit :

From: peder.holt_at_[hidden]
Date: 2007-09-28 16:11:33


Author: burbelgruff
Date: 2007-09-28 16:11:32 EDT (Fri, 28 Sep 2007)
New Revision: 39590
URL: http://svn.boost.org/trac/boost/changeset/39590

Log:
Modified tests to account for Borland compiler
Text files modified:
   trunk/libs/typeof/test/modifiers.cpp | 3 +++
   trunk/libs/typeof/test/test.hpp | 13 +++++++------
   2 files changed, 10 insertions(+), 6 deletions(-)

Modified: trunk/libs/typeof/test/modifiers.cpp
==============================================================================
--- trunk/libs/typeof/test/modifiers.cpp (original)
+++ trunk/libs/typeof/test/modifiers.cpp 2007-09-28 16:11:32 EDT (Fri, 28 Sep 2007)
@@ -14,3 +14,6 @@
 BOOST_STATIC_ASSERT(boost::type_of::test<const x>::value);
 BOOST_STATIC_ASSERT(boost::type_of::test<volatile x>::value);
 BOOST_STATIC_ASSERT(boost::type_of::test<volatile const x>::value);
+BOOST_STATIC_ASSERT(boost::type_of::test<const x&>::value);
+BOOST_STATIC_ASSERT(boost::type_of::test<const x*>::value);
+

Modified: trunk/libs/typeof/test/test.hpp
==============================================================================
--- trunk/libs/typeof/test/test.hpp (original)
+++ trunk/libs/typeof/test/test.hpp 2007-09-28 16:11:32 EDT (Fri, 28 Sep 2007)
@@ -8,23 +8,24 @@
 #include <boost/typeof/typeof.hpp>
 #include <boost/type_traits/is_same.hpp>
 #include <boost/static_assert.hpp>
+#include <boost/mpl/size_t.hpp>
 
 namespace boost { namespace type_of {
 
- template<class T, class U>
+ template<class T, class U>
     struct test_wrapper{};
 
- template<class T>
+ template<class T>
     T test_make(T*);
 
- template<class T>
+ template<class T>
     struct test
     {
- enum {value = boost::is_same<
+ BOOST_STATIC_CONSTANT(std::size_t,value = (boost::is_same<
             BOOST_TYPEOF_TPL(test_make((test_wrapper<T, int>*)0)),
             test_wrapper<T, int>
- >::value
- };
+ >::value)
+ );
     };
 
 }}


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