Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r72023 - in sandbox/coerce/boost/coerce: . detail
From: vexocide_at_[hidden]
Date: 2011-05-17 17:14:28


Author: vexocide
Date: 2011-05-17 17:14:26 EDT (Tue, 17 May 2011)
New Revision: 72023
URL: http://svn.boost.org/trac/boost/changeset/72023

Log:
Miscellaneous changes
Text files modified:
   sandbox/coerce/boost/coerce/coerce.hpp | 4 +++-
   sandbox/coerce/boost/coerce/detail/push_back.hpp | 1 +
   sandbox/coerce/boost/coerce/reserve.hpp | 28 ++++++++++++++--------------
   3 files changed, 18 insertions(+), 15 deletions(-)

Modified: sandbox/coerce/boost/coerce/coerce.hpp
==============================================================================
--- sandbox/coerce/boost/coerce/coerce.hpp (original)
+++ sandbox/coerce/boost/coerce/coerce.hpp 2011-05-17 17:14:26 EDT (Tue, 17 May 2011)
@@ -15,6 +15,8 @@
 #include <boost/coerce/detail/push_back.hpp>
 #include <boost/range/has_range_iterator.hpp>
 
+#include <boost/throw_exception.hpp>
+
 #include <typeinfo> // for std::bad_cast
 
 namespace boost { namespace coerce {
@@ -43,7 +45,7 @@
>::call(target, source);
 
         if (!result) {
- throw coerce::bad_cast();
+ throw_exception(coerce::bad_cast());
         }
 
         return target;

Modified: sandbox/coerce/boost/coerce/detail/push_back.hpp
==============================================================================
--- sandbox/coerce/boost/coerce/detail/push_back.hpp (original)
+++ sandbox/coerce/boost/coerce/detail/push_back.hpp 2011-05-17 17:14:26 EDT (Tue, 17 May 2011)
@@ -11,6 +11,7 @@
 #pragma once
 #endif
 
+#include <boost/config.hpp>
 #include <boost/mpl/bool.hpp>
 #include <boost/type_traits/detail/yes_no_type.hpp>
 

Modified: sandbox/coerce/boost/coerce/reserve.hpp
==============================================================================
--- sandbox/coerce/boost/coerce/reserve.hpp (original)
+++ sandbox/coerce/boost/coerce/reserve.hpp 2011-05-17 17:14:26 EDT (Tue, 17 May 2011)
@@ -21,10 +21,10 @@
 
 namespace boost { namespace coerce { namespace traits {
 
- template <typename Type>
+ template <typename T>
     struct reserve_size_impl {
         BOOST_STATIC_CONSTANT(std::size_t, value =
- 3 * sizeof(Type) + 1);
+ 3 * sizeof(T) + 1);
     };
 
     template <>
@@ -37,12 +37,12 @@
         BOOST_STATIC_CONSTANT(std::size_t, value = 1);
     };
 
- template <typename Type>
+ template <typename T>
     struct reserve_size_impl_integral {
         BOOST_STATIC_CONSTANT(std::size_t, value =
- std::numeric_limits<Type>::is_signed +
+ std::numeric_limits<T>::is_signed +
             1 +
- std::numeric_limits<Type>::digits10);
+ std::numeric_limits<T>::digits10);
     };
 
     template <>
@@ -81,12 +81,12 @@
 
 #endif // BOOST_HAS_LONG_LONG
 
- template <typename Type>
+ template <typename T>
     struct reserve_size_impl_floating_point {
         BOOST_STATIC_CONSTANT(std::size_t, value =
- std::numeric_limits<Type>::is_signed +
+ std::numeric_limits<T>::is_signed +
             8 +
- std::numeric_limits<Type>::digits10);
+ std::numeric_limits<T>::digits10);
     };
 
     template <>
@@ -106,17 +106,17 @@
         BOOST_STATIC_CONSTANT(std::size_t, value = 5);
     };
 
- template <typename Type>
- struct reserve_size_impl<boost::optional<Type> >
- : reserve_size_impl<Type> { };
+ template <typename T>
+ struct reserve_size_impl<boost::optional<T> >
+ : reserve_size_impl<T> { };
 
- template <typename Type, typename Enable = void>
+ template <typename T, typename Enable = void>
     struct reserve_size {
         typedef std::size_t type;
 
         static inline type
- call(Type const &) {
- return reserve_size_impl<Type>::value;
+ call(T const &) {
+ return reserve_size_impl<T>::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