summaryrefslogtreecommitdiffstats
path: root/contrib/libc++/include/ext
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2015-09-16 22:26:52 +0000
committerdim <dim@FreeBSD.org>2015-09-16 22:26:52 +0000
commitea5248cdc11d47e16b420831d52143ca4afb904a (patch)
treeaaccdba1a8c990ea730287a164e76e70733b424a /contrib/libc++/include/ext
parent5cc32d7f18f18fb3a5f4155b7f748cc7be60d2da (diff)
parent50ffe587e08aebe69879f2e5b67ba1304ff781b3 (diff)
downloadFreeBSD-src-ea5248cdc11d47e16b420831d52143ca4afb904a.zip
FreeBSD-src-ea5248cdc11d47e16b420831d52143ca4afb904a.tar.gz
Update libc++ to 3.7.0 release.
Diffstat (limited to 'contrib/libc++/include/ext')
-rw-r--r--contrib/libc++/include/ext/hash_map31
1 files changed, 9 insertions, 22 deletions
diff --git a/contrib/libc++/include/ext/hash_map b/contrib/libc++/include/ext/hash_map
index 36cd595..31fcedf 100644
--- a/contrib/libc++/include/ext/hash_map
+++ b/contrib/libc++/include/ext/hash_map
@@ -203,6 +203,7 @@ template <class Key, class T, class Hash, class Pred, class Alloc>
#include <__hash_table>
#include <functional>
#include <stdexcept>
+#include <type_traits>
#include <ext/__hash>
#if __DEPRECATED
@@ -213,16 +214,16 @@ template <class Key, class T, class Hash, class Pred, class Alloc>
#endif
#endif
+#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
+#endif
namespace __gnu_cxx {
using namespace std;
-template <class _Tp, class _Hash, bool = is_empty<_Hash>::value
-#if __has_feature(is_final)
- && !__is_final(_Hash)
-#endif
+template <class _Tp, class _Hash,
+ bool = is_empty<_Hash>::value && !__libcpp_is_final<_Hash>::value
>
class __hash_map_hasher
: private _Hash
@@ -255,10 +256,8 @@ public:
{return __hash_(__x);}
};
-template <class _Tp, class _Pred, bool = is_empty<_Pred>::value
-#if __has_feature(is_final)
- && !__is_final(_Pred)
-#endif
+template <class _Tp, class _Pred,
+ bool = is_empty<_Pred>::value && !__libcpp_is_final<_Pred>::value
>
class __hash_map_equal
: private _Pred
@@ -493,13 +492,7 @@ private:
typedef pair<key_type, mapped_type> __value_type;
typedef __hash_map_hasher<__value_type, hasher> __hasher;
typedef __hash_map_equal<__value_type, key_equal> __key_equal;
- typedef typename allocator_traits<allocator_type>::template
-#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES
- rebind_alloc<__value_type>
-#else
- rebind_alloc<__value_type>::other
-#endif
- __allocator_type;
+ typedef typename __rebind_alloc_helper<allocator_traits<allocator_type>, __value_type>::type __allocator_type;
typedef __hash_table<__value_type, __hasher,
__key_equal, __allocator_type> __table;
@@ -772,13 +765,7 @@ private:
typedef pair<key_type, mapped_type> __value_type;
typedef __hash_map_hasher<__value_type, hasher> __hasher;
typedef __hash_map_equal<__value_type, key_equal> __key_equal;
- typedef typename allocator_traits<allocator_type>::template
-#ifndef _LIBCPP_HAS_NO_TEMPLATE_ALIASES
- rebind_alloc<__value_type>
-#else
- rebind_alloc<__value_type>::other
-#endif
- __allocator_type;
+ typedef typename __rebind_alloc_helper<allocator_traits<allocator_type>, __value_type>::type __allocator_type;
typedef __hash_table<__value_type, __hasher,
__key_equal, __allocator_type> __table;
OpenPOWER on IntegriCloud