|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r86077 - in trunk/boost/type_traits: . detail
From: steveire_at_[hidden]
Date: 2013-09-30 12:01:57
Author: skelly
Date: 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013)
New Revision: 86077
URL: http://svn.boost.org/trac/boost/changeset/86077
Log:
TypeTraits: Remove obsolete GCC version checks.
Text files modified:
trunk/boost/type_traits/common_type.hpp | 2 +-
trunk/boost/type_traits/config.hpp | 1 -
trunk/boost/type_traits/detail/cv_traits_impl.hpp | 33 ---------------------------------
trunk/boost/type_traits/detail/has_binary_operator.hpp | 2 +-
trunk/boost/type_traits/detail/has_postfix_operator.hpp | 2 +-
trunk/boost/type_traits/detail/has_prefix_operator.hpp | 2 +-
trunk/boost/type_traits/is_const.hpp | 7 -------
trunk/boost/type_traits/is_lvalue_reference.hpp | 14 --------------
8 files changed, 4 insertions(+), 59 deletions(-)
Modified: trunk/boost/type_traits/common_type.hpp
==============================================================================
--- trunk/boost/type_traits/common_type.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/common_type.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -120,7 +120,7 @@
typedef BOOST_TYPEOF_TPL(declval_b() ? declval_T() : declval_U()) type;
#endif
-#if defined(__GNUC__) && __GNUC__ == 3 && (__GNUC_MINOR__ == 2 || __GNUC_MINOR__ == 3)
+#if defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ == 3
public:
void public_dummy_function_just_to_silence_warning();
#endif
Modified: trunk/boost/type_traits/config.hpp
==============================================================================
--- trunk/boost/type_traits/config.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/config.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -27,7 +27,6 @@
#endif
# if (BOOST_WORKAROUND(__MWERKS__, < 0x3000) \
- || !defined(__EDG_VERSION__) && BOOST_WORKAROUND(__GNUC__, < 3) \
|| BOOST_WORKAROUND(__IBMCPP__, < 600 ) \
|| BOOST_WORKAROUND(__BORLANDC__, < 0x5A0) \
|| defined(__ghs) \
Modified: trunk/boost/type_traits/detail/cv_traits_impl.hpp
==============================================================================
--- trunk/boost/type_traits/detail/cv_traits_impl.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/detail/cv_traits_impl.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -19,15 +19,8 @@
// implementation helper:
-#if !(BOOST_WORKAROUND(__GNUC__,== 3) && BOOST_WORKAROUND(__GNUC_MINOR__, <= 2))
namespace boost {
namespace detail {
-#else
-#include <boost/type_traits/detail/yes_no_type.hpp>
-namespace boost {
-namespace type_traits {
-namespace gcc8503 {
-#endif
template <typename T> struct cv_traits_imp {};
@@ -63,32 +56,6 @@
typedef T unqualified_type;
};
-#if BOOST_WORKAROUND(__GNUC__,== 3) && BOOST_WORKAROUND(__GNUC_MINOR__, <= 2)
-// We have to exclude function pointers
-// (see http://gcc.gnu.org/bugzilla/show_bug.cgi?8503)
-yes_type mini_funcptr_tester(...);
-no_type mini_funcptr_tester(const volatile void*);
-
-} // namespace gcc8503
-} // namespace type_traits
-
-namespace detail {
-
-// Use the implementation above for non function pointers
-template <typename T, unsigned Select
- = (unsigned)sizeof(::boost::type_traits::gcc8503::mini_funcptr_tester((T)0)) >
-struct cv_traits_imp : public ::boost::type_traits::gcc8503::cv_traits_imp<T> { };
-
-// Functions are never cv-qualified
-template <typename T> struct cv_traits_imp<T*,1>
-{
- BOOST_STATIC_CONSTANT(bool, is_const = false);
- BOOST_STATIC_CONSTANT(bool, is_volatile = false);
- typedef T unqualified_type;
-};
-
-#endif
-
} // namespace detail
} // namespace boost
Modified: trunk/boost/type_traits/detail/has_binary_operator.hpp
==============================================================================
--- trunk/boost/type_traits/detail/has_binary_operator.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/detail/has_binary_operator.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -36,7 +36,7 @@
// warning C4804: '<' : unsafe use of type 'bool' in operation
// warning C4805: '==' : unsafe mix of type 'bool' and type 'char' in operation
// cannot find another implementation -> declared as system header to suppress these warnings.
-#if defined(__GNUC__) && ((__GNUC__==3 && __GNUC_MINOR__>=1) || (__GNUC__>3))
+#if defined(__GNUC__)
# pragma GCC system_header
#elif defined(BOOST_MSVC)
# pragma warning ( push )
Modified: trunk/boost/type_traits/detail/has_postfix_operator.hpp
==============================================================================
--- trunk/boost/type_traits/detail/has_postfix_operator.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/detail/has_postfix_operator.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -22,7 +22,7 @@
#include <boost/type_traits/detail/bool_trait_def.hpp>
// avoid warnings
-#if defined(__GNUC__) && ((__GNUC__==3 && __GNUC_MINOR__>=1) || (__GNUC__>3))
+#if defined(__GNUC__)
# pragma GCC system_header
#elif defined(BOOST_MSVC)
# pragma warning ( push )
Modified: trunk/boost/type_traits/detail/has_prefix_operator.hpp
==============================================================================
--- trunk/boost/type_traits/detail/has_prefix_operator.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/detail/has_prefix_operator.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -30,7 +30,7 @@
// warning C4146: unary minus operator applied to unsigned type, result still unsigned
// warning C4804: '-' : unsafe use of type 'bool' in operation
// cannot find another implementation -> declared as system header to suppress these warnings.
-#if defined(__GNUC__) && ((__GNUC__==3 && __GNUC_MINOR__>=1) || (__GNUC__>3))
+#if defined(__GNUC__)
# pragma GCC system_header
#elif defined(BOOST_MSVC)
# pragma warning ( push )
Modified: trunk/boost/type_traits/is_const.hpp
==============================================================================
--- trunk/boost/type_traits/is_const.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/is_const.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -87,13 +87,6 @@
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_const,T& const volatile,false)
#endif
-#if defined(__GNUC__) && (__GNUC__ < 3)
-// special case for gcc where illegally cv-qualified reference types can be
-// generated in some corner cases:
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_const,T const,!(::boost::is_reference<T>::value))
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_const,T volatile const,!(::boost::is_reference<T>::value))
-#endif
-
#else
namespace detail {
Modified: trunk/boost/type_traits/is_lvalue_reference.hpp
==============================================================================
--- trunk/boost/type_traits/is_lvalue_reference.hpp Mon Sep 30 12:01:34 2013 (r86076)
+++ trunk/boost/type_traits/is_lvalue_reference.hpp 2013-09-30 12:01:57 EDT (Mon, 30 Sep 2013) (r86077)
@@ -50,20 +50,6 @@
BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_lvalue_reference,T& const volatile,true)
#endif
-#if defined(__GNUC__) && (__GNUC__ < 3)
-// these allow us to work around illegally cv-qualified reference
-// types.
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_lvalue_reference,T const ,::boost::is_lvalue_reference<T>::value)
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_lvalue_reference,T volatile ,::boost::is_lvalue_reference<T>::value)
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_1(typename T,is_lvalue_reference,T const volatile ,::boost::is_lvalue_reference<T>::value)
-// However, the above specializations confuse gcc 2.96 unless we also
-// supply these specializations for array types
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_2(typename T,unsigned long N,is_lvalue_reference,T[N],false)
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_2(typename T,unsigned long N,is_lvalue_reference,const T[N],false)
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_2(typename T,unsigned long N,is_lvalue_reference,volatile T[N],false)
-BOOST_TT_AUX_BOOL_TRAIT_PARTIAL_SPEC1_2(typename T,unsigned long N,is_lvalue_reference,const volatile T[N],false)
-#endif
-
#else
#ifdef BOOST_MSVC
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