[libcxx] [test] Fix Clang -Wunused-local-typedef, part 2/3.
These typedefs were completely unused. Fixes D29136. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@294155 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -68,7 +68,6 @@ test3(unsigned n, Allocator const &alloc = Allocator())
|
||||
{
|
||||
#if TEST_STD_VER > 11
|
||||
typedef std::deque<T, Allocator> C;
|
||||
typedef typename C::const_iterator const_iterator;
|
||||
{
|
||||
C d(n, alloc);
|
||||
assert(d.size() == n);
|
||||
|
||||
@@ -25,7 +25,6 @@ test3(unsigned n, Allocator const &alloc = Allocator())
|
||||
{
|
||||
#if TEST_STD_VER > 11
|
||||
typedef std::list<T, Allocator> C;
|
||||
typedef typename C::const_iterator const_iterator;
|
||||
{
|
||||
C d(n, alloc);
|
||||
assert(d.size() == n);
|
||||
|
||||
@@ -25,14 +25,11 @@ int main()
|
||||
{
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef std::pair<int, std::string> P;
|
||||
const C c;
|
||||
LIBCPP_ASSERT(c.bucket_count() == 0);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef std::pair<int, std::string> P;
|
||||
P a[] =
|
||||
{
|
||||
|
||||
@@ -44,7 +44,6 @@ int main()
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
const C c;
|
||||
assert(c.load_factor() == 0);
|
||||
}
|
||||
@@ -70,7 +69,6 @@ int main()
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string, std::hash<int>, std::equal_to<int>,
|
||||
min_allocator<std::pair<const int, std::string>>> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
const C c;
|
||||
assert(c.load_factor() == 0);
|
||||
}
|
||||
|
||||
@@ -25,8 +25,6 @@ int main()
|
||||
{
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef std::pair<int, std::string> P;
|
||||
const C c;
|
||||
assert(c.max_bucket_count() > 0);
|
||||
}
|
||||
@@ -34,8 +32,6 @@ int main()
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string, std::hash<int>, std::equal_to<int>,
|
||||
min_allocator<std::pair<const int, std::string>>> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef std::pair<int, std::string> P;
|
||||
const C c;
|
||||
assert(c.max_bucket_count() > 0);
|
||||
}
|
||||
|
||||
@@ -30,13 +30,11 @@ int main()
|
||||
{
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
const C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
c.max_load_factor(2.5);
|
||||
@@ -46,14 +44,12 @@ int main()
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string, std::hash<int>, std::equal_to<int>,
|
||||
min_allocator<std::pair<const int, std::string>>> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
const C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multimap<int, std::string, std::hash<int>, std::equal_to<int>,
|
||||
min_allocator<std::pair<const int, std::string>>> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
c.max_load_factor(2.5);
|
||||
|
||||
@@ -34,7 +34,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef test_allocator<std::pair<const int, std::string> > Alloc;
|
||||
typedef std::unordered_multimap<int, std::string, Hash, Compare, Alloc> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1, 1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(1, 2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -219,7 +218,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef other_allocator<std::pair<const int, std::string> > Alloc;
|
||||
typedef std::unordered_multimap<int, std::string, Hash, Compare, Alloc> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -404,7 +402,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef min_allocator<std::pair<const int, std::string> > Alloc;
|
||||
typedef std::unordered_multimap<int, std::string, Hash, Compare, Alloc> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc());
|
||||
C c2(0, Hash(2), Compare(2), Alloc());
|
||||
c2.max_load_factor(2);
|
||||
|
||||
@@ -33,7 +33,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef test_allocator<std::pair<const int, std::string> > Alloc;
|
||||
typedef std::unordered_multimap<int, std::string, Hash, Compare, Alloc> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1, 1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(1, 2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -218,7 +217,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef other_allocator<std::pair<const int, std::string> > Alloc;
|
||||
typedef std::unordered_multimap<int, std::string, Hash, Compare, Alloc> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -403,7 +401,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef min_allocator<std::pair<const int, std::string> > Alloc;
|
||||
typedef std::unordered_multimap<int, std::string, Hash, Compare, Alloc> C;
|
||||
typedef std::pair<int, std::string> P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc());
|
||||
C c2(0, Hash(2), Compare(2), Alloc());
|
||||
c2.max_load_factor(2);
|
||||
|
||||
@@ -25,14 +25,11 @@ int main()
|
||||
{
|
||||
{
|
||||
typedef std::unordered_multiset<int> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
const C c;
|
||||
LIBCPP_ASSERT(c.bucket_count() == 0);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multiset<int> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
P a[] =
|
||||
{
|
||||
@@ -52,15 +49,12 @@ int main()
|
||||
{
|
||||
typedef std::unordered_multiset<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
const C c;
|
||||
LIBCPP_ASSERT(c.bucket_count() == 0);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multiset<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
P a[] =
|
||||
{
|
||||
|
||||
@@ -43,7 +43,6 @@ int main()
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multiset<int> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.load_factor() == 0);
|
||||
}
|
||||
@@ -69,7 +68,6 @@ int main()
|
||||
{
|
||||
typedef std::unordered_multiset<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.load_factor() == 0);
|
||||
}
|
||||
|
||||
@@ -29,13 +29,11 @@ int main()
|
||||
{
|
||||
{
|
||||
typedef std::unordered_multiset<int> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multiset<int> C;
|
||||
typedef int P;
|
||||
C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
c.max_load_factor(2.5);
|
||||
@@ -45,14 +43,12 @@ int main()
|
||||
{
|
||||
typedef std::unordered_multiset<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_multiset<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef int P;
|
||||
C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
c.max_load_factor(2.5);
|
||||
|
||||
@@ -32,7 +32,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef test_allocator<int> Alloc;
|
||||
typedef std::unordered_multiset<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1, 1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(1, 2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -213,7 +212,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef other_allocator<int> Alloc;
|
||||
typedef std::unordered_multiset<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -394,7 +392,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef min_allocator<int> Alloc;
|
||||
typedef std::unordered_multiset<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc());
|
||||
C c2(0, Hash(2), Compare(2), Alloc());
|
||||
c2.max_load_factor(2);
|
||||
|
||||
@@ -32,7 +32,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef test_allocator<int> Alloc;
|
||||
typedef std::unordered_multiset<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1, 1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(1, 2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -213,7 +212,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef other_allocator<int> Alloc;
|
||||
typedef std::unordered_multiset<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -394,7 +392,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef min_allocator<int> Alloc;
|
||||
typedef std::unordered_multiset<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc());
|
||||
C c2(0, Hash(2), Compare(2), Alloc());
|
||||
c2.max_load_factor(2);
|
||||
|
||||
@@ -25,14 +25,11 @@ int main()
|
||||
{
|
||||
{
|
||||
typedef std::unordered_set<int> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
const C c;
|
||||
LIBCPP_ASSERT(c.bucket_count() == 0);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_set<int> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
P a[] =
|
||||
{
|
||||
@@ -51,14 +48,11 @@ int main()
|
||||
#if TEST_STD_VER >= 11
|
||||
{
|
||||
typedef std::unordered_set<int, std::hash<int>, std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
const C c;
|
||||
LIBCPP_ASSERT(c.bucket_count() == 0);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_set<int, std::hash<int>, std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef C::const_iterator I;
|
||||
typedef int P;
|
||||
P a[] =
|
||||
{
|
||||
|
||||
@@ -43,7 +43,6 @@ int main()
|
||||
}
|
||||
{
|
||||
typedef std::unordered_set<int> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.load_factor() == 0);
|
||||
}
|
||||
@@ -69,7 +68,6 @@ int main()
|
||||
{
|
||||
typedef std::unordered_set<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.load_factor() == 0);
|
||||
}
|
||||
|
||||
@@ -29,13 +29,11 @@ int main()
|
||||
{
|
||||
{
|
||||
typedef std::unordered_set<int> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_set<int> C;
|
||||
typedef int P;
|
||||
C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
c.max_load_factor(2.5);
|
||||
@@ -45,14 +43,12 @@ int main()
|
||||
{
|
||||
typedef std::unordered_set<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef int P;
|
||||
const C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
}
|
||||
{
|
||||
typedef std::unordered_set<int, std::hash<int>,
|
||||
std::equal_to<int>, min_allocator<int>> C;
|
||||
typedef int P;
|
||||
C c;
|
||||
assert(c.max_load_factor() == 1);
|
||||
c.max_load_factor(2.5);
|
||||
|
||||
@@ -32,7 +32,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef test_allocator<int> Alloc;
|
||||
typedef std::unordered_set<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1, 1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(1, 2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -213,7 +212,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef other_allocator<int> Alloc;
|
||||
typedef std::unordered_set<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -394,7 +392,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef min_allocator<int> Alloc;
|
||||
typedef std::unordered_set<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc());
|
||||
C c2(0, Hash(2), Compare(2), Alloc());
|
||||
c2.max_load_factor(2);
|
||||
|
||||
@@ -32,7 +32,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef test_allocator<int> Alloc;
|
||||
typedef std::unordered_set<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1, 1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(1, 2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -213,7 +212,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef other_allocator<int> Alloc;
|
||||
typedef std::unordered_set<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc(1));
|
||||
C c2(0, Hash(2), Compare(2), Alloc(2));
|
||||
c2.max_load_factor(2);
|
||||
@@ -394,7 +392,6 @@ int main()
|
||||
typedef test_compare<std::equal_to<int> > Compare;
|
||||
typedef min_allocator<int> Alloc;
|
||||
typedef std::unordered_set<int, Hash, Compare, Alloc> C;
|
||||
typedef int P;
|
||||
C c1(0, Hash(1), Compare(1), Alloc());
|
||||
C c2(0, Hash(2), Compare(2), Alloc());
|
||||
c2.max_load_factor(2);
|
||||
|
||||
Reference in New Issue
Block a user