[cfe-commits] [libcxx] r140014 - /libcxx/trunk/include/type_traits
Howard Hinnant
hhinnant at apple.com
Mon Sep 19 06:19:32 PDT 2011
Author: hhinnant
Date: Mon Sep 19 08:19:31 2011
New Revision: 140014
URL: http://llvm.org/viewvc/llvm-project?rev=140014&view=rev
Log:
Removed unneeded boost implementation of is_base_of
Modified:
libcxx/trunk/include/type_traits
Modified: libcxx/trunk/include/type_traits
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/type_traits?rev=140014&r1=140013&r2=140014&view=diff
==============================================================================
--- libcxx/trunk/include/type_traits (original)
+++ libcxx/trunk/include/type_traits Mon Sep 19 08:19:31 2011
@@ -733,51 +733,7 @@
#else // __has_feature(is_base_of)
-// (C) Copyright Rani Sharoni 2003.
-// Use, modification and distribution are subject to the Boost Software License,
-// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
-// http://www.boost.org/LICENSE_1_0.txt).
-//
-// See http://www.boost.org/libs/type_traits for most recent version including documentation.
-
-template <class _Bp, class _Dp>
-struct __is_base_of_tests
-{
- template <class _Tp>
- static char __test(const volatile _Dp*, _Tp);
- static __two __test(const volatile _Bp*, int);
-};
-
-template <class _Bp, class _Dp>
-struct __is_base_of_imp
-{
- struct __host
- {
- operator const volatile _Bp*() const;
- operator const volatile _Dp*();
- };
-
- static const size_t __complete_check = sizeof(_Dp);
- static const bool value = sizeof(__is_base_of_tests<_Bp, _Dp>::__test(__host(), 0)) == 1;
-};
-
-template <class _Bp, class _Dp, bool = is_class<_Bp>::value,
- bool = is_class<_Dp>::value,
- bool = is_same<_Bp, _Dp>::value>
-struct __libcpp_base_of : public false_type {};
-
-template <class _Bp, class _Dp>
-struct __libcpp_base_of<_Bp, _Dp, true, true, true> : public true_type {};
-
-template <class _Bp, class _Dp>
-struct __libcpp_base_of<_Bp, _Dp, true, true, false>
- : public integral_constant<bool, __is_base_of_imp<_Bp, _Dp>::value> {};
-
-template <class _Bp, class _Dp>
-struct _LIBCPP_VISIBLE is_base_of
- : public __libcpp_base_of<typename remove_cv<_Bp>::type, typename remove_cv<_Dp>::type>
-{
-};
+#error is_base_of not implemented.
#endif // __has_feature(is_base_of)
More information about the cfe-commits
mailing list