|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r49169 - trunk/boost/type_traits
From: john_at_[hidden]
Date: 2008-10-07 13:17:58
Author: johnmaddock
Date: 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
New Revision: 49169
URL: http://svn.boost.org/trac/boost/changeset/49169
Log:
Fixes 2346.
Patches for the codegear compiler, with intrinsic type_traits support enabled.
Text files modified:
trunk/boost/type_traits/add_pointer.hpp | 2 +-
trunk/boost/type_traits/config.hpp | 2 +-
trunk/boost/type_traits/extent.hpp | 13 ++++++++++++-
trunk/boost/type_traits/intrinsics.hpp | 29 +++++++++++++++++++++++++++++
trunk/boost/type_traits/is_arithmetic.hpp | 8 ++++++++
trunk/boost/type_traits/is_array.hpp | 5 +++--
trunk/boost/type_traits/is_base_and_derived.hpp | 4 ++++
trunk/boost/type_traits/is_compound.hpp | 6 ++++++
trunk/boost/type_traits/is_const.hpp | 8 ++++++--
trunk/boost/type_traits/is_function.hpp | 10 +++++++++-
trunk/boost/type_traits/is_fundamental.hpp | 4 ++++
trunk/boost/type_traits/is_integral.hpp | 5 +++++
trunk/boost/type_traits/is_member_function_pointer.hpp | 4 +++-
trunk/boost/type_traits/is_member_pointer.hpp | 4 +++-
trunk/boost/type_traits/is_pointer.hpp | 4 +++-
trunk/boost/type_traits/is_reference.hpp | 6 ++++--
trunk/boost/type_traits/is_signed.hpp | 8 ++++++++
trunk/boost/type_traits/is_unsigned.hpp | 9 ++++++++-
trunk/boost/type_traits/is_void.hpp | 5 +++++
trunk/boost/type_traits/is_volatile.hpp | 6 ++++--
trunk/boost/type_traits/rank.hpp | 8 ++++++++
trunk/boost/type_traits/remove_all_extents.hpp | 2 +-
trunk/boost/type_traits/remove_bounds.hpp | 2 +-
trunk/boost/type_traits/remove_extent.hpp | 2 +-
trunk/boost/type_traits/remove_reference.hpp | 2 +-
trunk/boost/type_traits/type_with_alignment.hpp | 2 ++
26 files changed, 140 insertions(+), 20 deletions(-)
Modified: trunk/boost/type_traits/add_pointer.hpp
==============================================================================
--- trunk/boost/type_traits/add_pointer.hpp (original)
+++ trunk/boost/type_traits/add_pointer.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -18,7 +18,7 @@
namespace detail {
-#if defined(__BORLANDC__) && (__BORLANDC__ < 0x600)
+#if defined(__BORLANDC__) && (__BORLANDC__ < 0x5A0)
//
// For some reason this implementation stops Borlands compiler
// from dropping cv-qualifiers, it still fails with references
Modified: trunk/boost/type_traits/config.hpp
==============================================================================
--- trunk/boost/type_traits/config.hpp (original)
+++ trunk/boost/type_traits/config.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -30,7 +30,7 @@
|| BOOST_WORKAROUND(BOOST_MSVC, <= 1301) \
|| !defined(__EDG_VERSION__) && BOOST_WORKAROUND(__GNUC__, < 3) \
|| BOOST_WORKAROUND(__IBMCPP__, < 600 ) \
- || BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564)) \
+ || BOOST_WORKAROUND(__BORLANDC__, < 0x5A0) \
|| defined(__ghs) \
|| BOOST_WORKAROUND(__HP_aCC, < 60700) \
|| BOOST_WORKAROUND(MPW_CPLUS, BOOST_TESTED_AT(0x890)) \
Modified: trunk/boost/type_traits/extent.hpp
==============================================================================
--- trunk/boost/type_traits/extent.hpp (original)
+++ trunk/boost/type_traits/extent.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -17,6 +17,15 @@
namespace detail{
+#if defined( __CODEGEARC__ )
+ // wrap the impl as main trait provides additional MPL lambda support
+ template < typename T, std::size_t N >
+ struct extent_imp {
+ static const std::size_t value = __array_extent(T, N);
+ };
+
+#else
+
template <class T, std::size_t N>
struct extent_imp
{
@@ -114,7 +123,9 @@
};
#endif
#endif
-}
+
+#endif // non-CodeGear implementation
+} // ::boost::detail
template <class T, std::size_t N = 0>
struct extent
Modified: trunk/boost/type_traits/intrinsics.hpp
==============================================================================
--- trunk/boost/type_traits/intrinsics.hpp (original)
+++ trunk/boost/type_traits/intrinsics.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -153,6 +153,35 @@
# define BOOST_HAS_TYPE_TRAITS_INTRINSICS
#endif
+# if defined(__CODEGEARC__)
+# include <boost/type_traits/is_same.hpp>
+# include <boost/type_traits/is_reference.hpp>
+# include <boost/type_traits/is_volatile.hpp>
+# include <boost/type_traits/is_void.hpp>
+
+# define BOOST_IS_UNION(T) __is_union(T)
+# define BOOST_IS_POD(T) __is_pod(T)
+# define BOOST_IS_EMPTY(T) __is_empty(T)
+# define BOOST_HAS_TRIVIAL_CONSTRUCTOR(T) (__has_trivial_default_constructor(T) || is_void<T>::value)
+# define BOOST_HAS_TRIVIAL_COPY(T) (__has_trivial_copy_constructor(T) && !is_volatile<T>::value && !is_reference<T>::value || is_void<T>::value)
+# define BOOST_HAS_TRIVIAL_ASSIGN(T) (__has_trivial_assign(T) && !is_volatile<T>::value || is_void<T>::value)
+# define BOOST_HAS_TRIVIAL_DESTRUCTOR(T) (__has_trivial_destructor(T) || is_void<T>::value)
+# define BOOST_HAS_NOTHROW_CONSTRUCTOR(T) (__has_nothrow_default_constructor(T) || is_void<T>::value)
+# define BOOST_HAS_NOTHROW_COPY(T) (__has_nothrow_copy_constructor(T) && !is_volatile<T>::value && !is_reference<T>::value || is_void<T>::value)
+# define BOOST_HAS_NOTHROW_ASSIGN(T) (__has_nothrow_assign(T) && !is_volatile<T>::value || is_void<T>::value)
+# define BOOST_HAS_VIRTUAL_DESTRUCTOR(T) __has_virtual_destructor(T)
+
+# define BOOST_IS_ABSTRACT(T) __is_abstract(T)
+# define BOOST_IS_BASE_OF(T,U) (__is_base_of(T,U) && !is_void<T>::value && !is_void<U>::value)
+# define BOOST_IS_CLASS(T) __is_class(T)
+# define BOOST_IS_CONVERTIBLE(T,U) (__is_convertible(T,U) || is_void<U>::value)
+# define BOOST_IS_ENUM(T) __is_enum(T)
+# define BOOST_IS_POLYMORPHIC(T) __is_polymorphic(T)
+# define BOOST_ALIGNMENT_OF(T) alignof(T)
+
+# define BOOST_HAS_TYPE_TRAITS_INTRINSICS
+#endif
+
#ifndef BOOST_IS_UNION
# define BOOST_IS_UNION(T) false
#endif
Modified: trunk/boost/type_traits/is_arithmetic.hpp
==============================================================================
--- trunk/boost/type_traits/is_arithmetic.hpp (original)
+++ trunk/boost/type_traits/is_arithmetic.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -9,16 +9,19 @@
#ifndef BOOST_TT_IS_ARITHMETIC_HPP_INCLUDED
#define BOOST_TT_IS_ARITHMETIC_HPP_INCLUDED
+#if !defined( __CODEGEARC__ )
#include <boost/type_traits/is_integral.hpp>
#include <boost/type_traits/is_float.hpp>
#include <boost/type_traits/detail/ice_or.hpp>
#include <boost/config.hpp>
+#endif
// should be the last #include
#include <boost/type_traits/detail/bool_trait_def.hpp>
namespace boost {
+#if !defined(__CODEGEARC__)
namespace detail {
template< typename T >
@@ -32,9 +35,14 @@
};
} // namespace detail
+#endif
//* is a type T an arithmetic type described in the standard (3.9.1p8)
+#if defined(__CODEGEARC__)
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_arithmetic,T,__is_arithmetic(T))
+#else
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_arithmetic,T,::boost::detail::is_arithmetic_impl<T>::value)
+#endif
} // namespace boost
Modified: trunk/boost/type_traits/is_array.hpp
==============================================================================
--- trunk/boost/type_traits/is_array.hpp (original)
+++ trunk/boost/type_traits/is_array.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -28,8 +28,9 @@
namespace boost {
-#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
-
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_array,T,__is_array(T))
+#elif !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION)
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_array,T,false)
#if !defined(BOOST_NO_ARRAY_TYPE_SPECIALIZATIONS)
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,is_array,T[N],true)
Modified: trunk/boost/type_traits/is_base_and_derived.hpp
==============================================================================
--- trunk/boost/type_traits/is_base_and_derived.hpp (original)
+++ trunk/boost/type_traits/is_base_and_derived.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -240,6 +240,10 @@
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC2_2(typename Base,typename Derived,is_base_and_derived,Base&,Derived&,false)
#endif
+#if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610))
+BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC2_1(typename Base,is_base_and_derived,Base,Base,false)
+#endif
+
} // namespace boost
#include <boost/type_traits/detail/bool_trait_undef.hpp>
Modified: trunk/boost/type_traits/is_compound.hpp
==============================================================================
--- trunk/boost/type_traits/is_compound.hpp (original)
+++ trunk/boost/type_traits/is_compound.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -18,6 +18,7 @@
namespace boost {
+#if !defined( __CODEGEARC__ )
namespace detail {
template <typename T>
@@ -30,8 +31,13 @@
};
} // namespace detail
+#endif // !defined( __CODEGEARC__ )
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_compound,T,__is_compound(T))
+#else
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_compound,T,::boost::detail::is_compound_impl<T>::value)
+#endif
} // namespace boost
Modified: trunk/boost/type_traits/is_const.hpp
==============================================================================
--- trunk/boost/type_traits/is_const.hpp (original)
+++ trunk/boost/type_traits/is_const.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -44,7 +44,11 @@
namespace boost {
-#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
+#if defined( __CODEGEARC__ )
+
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_const,T,__is_const(T))
+
+#elif !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION)
//* is a type T declared const - is_const<T>
#if BOOST_WORKAROUND(BOOST_MSVC, < 1400)
@@ -54,7 +58,7 @@
#endif
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_const,T&,false)
-#if defined(__BORLANDC__) && (__BORLANDC__ < 0x600)
+#if defined(BOOST_ILLEGAL_CV_REFERENCES)
// these are illegal specialisations; cv-qualifies applied to
// references have no effect according to [8.3.2p1],
// C++ Builder requires them though as it treats cv-qualified
Modified: trunk/boost/type_traits/is_function.hpp
==============================================================================
--- trunk/boost/type_traits/is_function.hpp (original)
+++ trunk/boost/type_traits/is_function.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -32,6 +32,9 @@
// function pointers to void*.
namespace boost {
+
+#if !defined( __CODEGEARC__ )
+
namespace detail {
#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !defined(BOOST_TT_TEST_MS_FUNC_SIGS)
@@ -86,8 +89,13 @@
} // namespace detail
-BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_function,T,::boost::detail::is_function_impl<T>::value)
+#endif // !defined( __CODEGEARC__ )
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_function,T,__is_function(T))
+#else
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_function,T,::boost::detail::is_function_impl<T>::value)
+#endif
} // namespace boost
#include <boost/type_traits/detail/bool_trait_undef.hpp>
Modified: trunk/boost/type_traits/is_fundamental.hpp
==============================================================================
--- trunk/boost/type_traits/is_fundamental.hpp (original)
+++ trunk/boost/type_traits/is_fundamental.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -32,7 +32,11 @@
} // namespace detail
//* is a type T a fundamental type described in the standard (3.9.1)
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_fundamental,T,__is_fundamental(T))
+#else
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_fundamental,T,::boost::detail::is_fundamental_impl<T>::value)
+#endif
} // namespace boost
Modified: trunk/boost/type_traits/is_integral.hpp
==============================================================================
--- trunk/boost/type_traits/is_integral.hpp (original)
+++ trunk/boost/type_traits/is_integral.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -19,6 +19,9 @@
//* is a type T an [cv-qualified-] integral type described in the standard (3.9.1p3)
// as an extention we include long long, as this is likely to be added to the
// standard at a later date
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_integral,T,__is_integral(T))
+#else
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_integral,T,false)
BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned char,true)
@@ -66,6 +69,8 @@
BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,__int64,true)
#endif
+#endif // non-CodeGear implementation
+
} // namespace boost
#include <boost/type_traits/detail/bool_trait_undef.hpp>
Modified: trunk/boost/type_traits/is_member_function_pointer.hpp
==============================================================================
--- trunk/boost/type_traits/is_member_function_pointer.hpp (original)
+++ trunk/boost/type_traits/is_member_function_pointer.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -37,7 +37,9 @@
namespace boost {
-#if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !BOOST_WORKAROUND(__BORLANDC__, < 0x600) && !defined(BOOST_TT_TEST_MS_FUNC_SIGS)
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_member_function_pointer,T,__is_member_function_pointer( T ))
+#elif !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) && !BOOST_WORKAROUND(__BORLANDC__, < 0x600) && !defined(BOOST_TT_TEST_MS_FUNC_SIGS)
BOOST_TT_AUX_BOOL_TRAIT_DEF1(
is_member_function_pointer
Modified: trunk/boost/type_traits/is_member_pointer.hpp
==============================================================================
--- trunk/boost/type_traits/is_member_pointer.hpp (original)
+++ trunk/boost/type_traits/is_member_pointer.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -40,7 +40,9 @@
namespace boost {
-#if BOOST_WORKAROUND(__BORLANDC__, < 0x600)
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_member_pointer,T,__is_member_pointer(T))
+#elif BOOST_WORKAROUND(__BORLANDC__, < 0x600)
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_member_pointer,T,false)
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_2(typename T,typename U,is_member_pointer,U T::*,true)
Modified: trunk/boost/type_traits/is_pointer.hpp
==============================================================================
--- trunk/boost/type_traits/is_pointer.hpp (original)
+++ trunk/boost/type_traits/is_pointer.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -42,7 +42,9 @@
namespace boost {
-#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_pointer,T,__is_pointer(T))
+#elif !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION)
namespace detail {
Modified: trunk/boost/type_traits/is_reference.hpp
==============================================================================
--- trunk/boost/type_traits/is_reference.hpp (original)
+++ trunk/boost/type_traits/is_reference.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -33,12 +33,14 @@
namespace boost {
-#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_reference,T,__is_reference(T))
+#elif !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION)
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_reference,T,false)
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_reference,T&,true)
-#if defined(__BORLANDC__) && !defined(__COMO__) && (__BORLANDC__ < 0x600)
+#if defined(BOOST_ILLEGAL_CV_REFERENCES)
// these are illegal specialisations; cv-qualifies applied to
// references have no effect according to [8.3.2p1],
// C++ Builder requires them though as it treats cv-qualified
Modified: trunk/boost/type_traits/is_signed.hpp
==============================================================================
--- trunk/boost/type_traits/is_signed.hpp (original)
+++ trunk/boost/type_traits/is_signed.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -20,6 +20,8 @@
namespace boost {
+#if !defined( __CODEGEARC__ )
+
namespace detail{
#if !(defined(__EDG_VERSION__) && __EDG_VERSION__ <= 238)
@@ -110,7 +112,13 @@
}
+#endif // !defined( __CODEGEARC__ )
+
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_signed,T,__is_signed(T))
+#else
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_signed,T,::boost::detail::is_signed_imp<T>::value)
+#endif
} // namespace boost
Modified: trunk/boost/type_traits/is_unsigned.hpp
==============================================================================
--- trunk/boost/type_traits/is_unsigned.hpp (original)
+++ trunk/boost/type_traits/is_unsigned.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -20,6 +20,8 @@
namespace boost {
+#if !defined( __CODEGEARC__ )
+
namespace detail{
#if !(defined(__EDG_VERSION__) && __EDG_VERSION__ <= 238)
@@ -104,10 +106,15 @@
#endif
-
}
+#endif // !defined( __CODEGEARC__ )
+
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_unsigned,T,__is_unsigned(T))
+#else
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_unsigned,T,::boost::detail::is_unsigned_imp<T>::value)
+#endif
} // namespace boost
Modified: trunk/boost/type_traits/is_void.hpp
==============================================================================
--- trunk/boost/type_traits/is_void.hpp (original)
+++ trunk/boost/type_traits/is_void.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -17,6 +17,9 @@
namespace boost {
//* is a type T void - is_void<T>
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_void,T,__is_void(T))
+#else
BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_void,T,false)
BOOST_TT_AUX_BOOL_TRAIT_SPEC1(is_void,void,true)
@@ -26,6 +29,8 @@
BOOST_TT_AUX_BOOL_TRAIT_SPEC1(is_void,void const volatile,true)
#endif
+#endif // non-CodeGear implementation
+
} // namespace boost
#include <boost/type_traits/detail/bool_trait_undef.hpp>
Modified: trunk/boost/type_traits/is_volatile.hpp
==============================================================================
--- trunk/boost/type_traits/is_volatile.hpp (original)
+++ trunk/boost/type_traits/is_volatile.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -41,7 +41,9 @@
namespace boost {
-#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_volatile,T,__is_volatile(T))
+#elif !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION)
//* is a type T declared volatile - is_volatile<T>
#if BOOST_WORKAROUND(BOOST_MSVC, < 1400)
@@ -51,7 +53,7 @@
#endif
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_volatile,T&,false)
-#if defined(__BORLANDC__) && (__BORLANDC__ < 0x600)
+#if defined(BOOST_ILLEGAL_CV_REFERENCES)
// these are illegal specialisations; cv-qualifies applied to
// references have no effect according to [8.3.2p1],
// C++ Builder requires them though as it treats cv-qualified
Modified: trunk/boost/type_traits/rank.hpp
==============================================================================
--- trunk/boost/type_traits/rank.hpp (original)
+++ trunk/boost/type_traits/rank.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -15,6 +15,8 @@
namespace boost {
+#if !defined( __CODEGEARC__ )
+
namespace detail{
template <class T, std::size_t N>
@@ -72,7 +74,13 @@
#endif
}
+#endif // !defined( __CODEGEARC__ )
+
+#if defined( __CODEGEARC__ )
+BOOST_TT_AUX_SIZE_T_TRAIT_DEF1(rank,T,__array_rank(T))
+#else
BOOST_TT_AUX_SIZE_T_TRAIT_DEF1(rank,T,(::boost::detail::rank_imp<T,0>::value))
+#endif
} // namespace boost
Modified: trunk/boost/type_traits/remove_all_extents.hpp
==============================================================================
--- trunk/boost/type_traits/remove_all_extents.hpp (original)
+++ trunk/boost/type_traits/remove_all_extents.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -31,7 +31,7 @@
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_all_extents,T const[N],typename boost::remove_all_extents<T const>::type type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_all_extents,T volatile[N],typename boost::remove_all_extents<T volatile>::type type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_all_extents,T const volatile[N],typename boost::remove_all_extents<T const volatile>::type type)
-#if !BOOST_WORKAROUND(__BORLANDC__, < 0x600) && !defined(__IBMCPP__) && !BOOST_WORKAROUND(__DMC__, BOOST_TESTED_AT(0x840))
+#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x610)) && !defined(__IBMCPP__) && !BOOST_WORKAROUND(__DMC__, BOOST_TESTED_AT(0x840))
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_all_extents,T[],typename boost::remove_all_extents<T>::type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_all_extents,T const[],typename boost::remove_all_extents<T const>::type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_all_extents,T volatile[],typename boost::remove_all_extents<T volatile>::type)
Modified: trunk/boost/type_traits/remove_bounds.hpp
==============================================================================
--- trunk/boost/type_traits/remove_bounds.hpp (original)
+++ trunk/boost/type_traits/remove_bounds.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -31,7 +31,7 @@
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_bounds,T const[N],T const type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_bounds,T volatile[N],T volatile type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_bounds,T const volatile[N],T const volatile type)
-#if !BOOST_WORKAROUND(__BORLANDC__, < 0x600) && !defined(__IBMCPP__) && !BOOST_WORKAROUND(__DMC__, BOOST_TESTED_AT(0x840))
+#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x610)) && !defined(__IBMCPP__) && !BOOST_WORKAROUND(__DMC__, BOOST_TESTED_AT(0x840))
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_bounds,T[],T)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_bounds,T const[],T const)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_bounds,T volatile[],T volatile)
Modified: trunk/boost/type_traits/remove_extent.hpp
==============================================================================
--- trunk/boost/type_traits/remove_extent.hpp (original)
+++ trunk/boost/type_traits/remove_extent.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -31,7 +31,7 @@
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_extent,T const[N],T const type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_extent,T volatile[N],T volatile type)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_2(typename T,std::size_t N,remove_extent,T const volatile[N],T const volatile type)
-#if !BOOST_WORKAROUND(__BORLANDC__, < 0x600) && !defined(__IBMCPP__) && !BOOST_WORKAROUND(__DMC__, BOOST_TESTED_AT(0x840))
+#if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x610)) && !defined(__IBMCPP__) && !BOOST_WORKAROUND(__DMC__, BOOST_TESTED_AT(0x840))
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_extent,T[],T)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_extent,T const[],T const)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_extent,T volatile[],T volatile)
Modified: trunk/boost/type_traits/remove_reference.hpp
==============================================================================
--- trunk/boost/type_traits/remove_reference.hpp (original)
+++ trunk/boost/type_traits/remove_reference.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -27,7 +27,7 @@
BOOST_TT_AUX_TYPE_TRAIT_DEF1(remove_reference,T,T)
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,remove_reference,T&,T)
-#if defined(__BORLANDC__) && (__BORLANDC__ < 0x600)
+#if defined(BOOST_ILLEGAL_CV_REFERENCES)
// these are illegal specialisations; cv-qualifies applied to
// references have no effect according to [8.3.2p1],
// C++ Builder requires them though as it treats cv-qualified
Modified: trunk/boost/type_traits/type_with_alignment.hpp
==============================================================================
--- trunk/boost/type_traits/type_with_alignment.hpp (original)
+++ trunk/boost/type_traits/type_with_alignment.hpp 2008-10-07 13:17:55 EDT (Tue, 07 Oct 2008)
@@ -357,10 +357,12 @@
typedef ::boost::align::a16 max_align;
+//#if ! BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610))
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_pod,::boost::align::a2,true)
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_pod,::boost::align::a4,true)
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_pod,::boost::align::a8,true)
BOOST_TT_AUX_BOOL_TRAIT_IMPL_SPEC1(is_pod,::boost::align::a16,true)
+//#endif
}
template <std::size_t N> struct type_with_alignment
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