Fix static assert problem on gcc; remove XFAILs that I put in in r274250
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@274285 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -938,10 +938,6 @@ private:
|
|||||||
typedef allocator_traits<__node_base_allocator> __node_base_traits;
|
typedef allocator_traits<__node_base_allocator> __node_base_traits;
|
||||||
static_assert((is_same<__node_base_pointer, typename __node_base_traits::pointer>::value),
|
static_assert((is_same<__node_base_pointer, typename __node_base_traits::pointer>::value),
|
||||||
"Allocator does not rebind pointers in a sane manner.");
|
"Allocator does not rebind pointers in a sane manner.");
|
||||||
static_assert((is_copy_constructible<key_equal>::value),
|
|
||||||
"Predicate must be copy-constructible.");
|
|
||||||
static_assert((is_copy_constructible<hasher>::value),
|
|
||||||
"Hasher must be copy-constructible.");
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
@@ -1479,6 +1475,10 @@ __hash_table<_Tp, _Hash, _Equal, _Alloc>::__hash_table(__hash_table&& __u,
|
|||||||
template <class _Tp, class _Hash, class _Equal, class _Alloc>
|
template <class _Tp, class _Hash, class _Equal, class _Alloc>
|
||||||
__hash_table<_Tp, _Hash, _Equal, _Alloc>::~__hash_table()
|
__hash_table<_Tp, _Hash, _Equal, _Alloc>::~__hash_table()
|
||||||
{
|
{
|
||||||
|
static_assert((is_copy_constructible<key_equal>::value),
|
||||||
|
"Predicate must be copy-constructible.");
|
||||||
|
static_assert((is_copy_constructible<hasher>::value),
|
||||||
|
"Hasher must be copy-constructible.");
|
||||||
__deallocate(__p1_.first().__next_);
|
__deallocate(__p1_.first().__next_);
|
||||||
#if _LIBCPP_DEBUG_LEVEL >= 2
|
#if _LIBCPP_DEBUG_LEVEL >= 2
|
||||||
__get_db()->__erase_c(this);
|
__get_db()->__erase_c(this);
|
||||||
|
|||||||
@@ -946,8 +946,6 @@ private:
|
|||||||
typedef allocator_traits<__node_base_allocator> __node_base_traits;
|
typedef allocator_traits<__node_base_allocator> __node_base_traits;
|
||||||
static_assert((is_same<__node_base_pointer, typename __node_base_traits::pointer>::value),
|
static_assert((is_same<__node_base_pointer, typename __node_base_traits::pointer>::value),
|
||||||
"Allocator does not rebind pointers in a sane manner.");
|
"Allocator does not rebind pointers in a sane manner.");
|
||||||
static_assert((is_copy_constructible<value_compare>::value),
|
|
||||||
"Comparator must be copy-constructible.");
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
__node_pointer __begin_node_;
|
__node_pointer __begin_node_;
|
||||||
@@ -1707,6 +1705,8 @@ __tree<_Tp, _Compare, _Allocator>::operator=(__tree&& __t)
|
|||||||
template <class _Tp, class _Compare, class _Allocator>
|
template <class _Tp, class _Compare, class _Allocator>
|
||||||
__tree<_Tp, _Compare, _Allocator>::~__tree()
|
__tree<_Tp, _Compare, _Allocator>::~__tree()
|
||||||
{
|
{
|
||||||
|
static_assert((is_copy_constructible<value_compare>::value),
|
||||||
|
"Comparator must be copy-constructible.");
|
||||||
destroy(__root());
|
destroy(__root());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,6 @@
|
|||||||
// Check that std::map and it's iterators can be instantiated with an incomplete
|
// Check that std::map and it's iterators can be instantiated with an incomplete
|
||||||
// type.
|
// type.
|
||||||
|
|
||||||
// XFAIL: gcc
|
|
||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
struct A {
|
struct A {
|
||||||
|
|||||||
@@ -13,8 +13,6 @@
|
|||||||
|
|
||||||
// map();
|
// map();
|
||||||
|
|
||||||
// XFAIL: gcc
|
|
||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
struct X
|
struct X
|
||||||
|
|||||||
@@ -12,8 +12,6 @@
|
|||||||
// Check that std::multimap and it's iterators can be instantiated with an incomplete
|
// Check that std::multimap and it's iterators can be instantiated with an incomplete
|
||||||
// type.
|
// type.
|
||||||
|
|
||||||
// XFAIL: gcc
|
|
||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
struct A {
|
struct A {
|
||||||
|
|||||||
@@ -13,8 +13,6 @@
|
|||||||
|
|
||||||
// multimap();
|
// multimap();
|
||||||
|
|
||||||
// XFAIL: gcc
|
|
||||||
|
|
||||||
#include <map>
|
#include <map>
|
||||||
|
|
||||||
struct X
|
struct X
|
||||||
|
|||||||
@@ -13,8 +13,6 @@
|
|||||||
// Check that std::unordered_map and it's iterators can be instantiated with an incomplete
|
// Check that std::unordered_map and it's iterators can be instantiated with an incomplete
|
||||||
// type.
|
// type.
|
||||||
|
|
||||||
// XFAIL: gcc
|
|
||||||
|
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
||||||
template <class Tp>
|
template <class Tp>
|
||||||
|
|||||||
@@ -13,8 +13,6 @@
|
|||||||
// Check that std::unordered_multimap and it's iterators can be instantiated with an incomplete
|
// Check that std::unordered_multimap and it's iterators can be instantiated with an incomplete
|
||||||
// type.
|
// type.
|
||||||
|
|
||||||
// XFAIL: gcc
|
|
||||||
|
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
||||||
template <class Tp>
|
template <class Tp>
|
||||||
|
|||||||
Reference in New Issue
Block a user