summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarshall Clow <mclow.lists@gmail.com>2016-06-07 15:49:39 +0000
committerMarshall Clow <mclow.lists@gmail.com>2016-06-07 15:49:39 +0000
commit6a23af0f338acaa9c1665c0a34d231f2b1574898 (patch)
treeeb571b7f1e9159d8ea74252fecaa8d96615eb7be
parent4fa9f3ae45206639c800639a40ece9b3bbeeb433 (diff)
downloadbcm5719-llvm-6a23af0f338acaa9c1665c0a34d231f2b1574898.tar.gz
bcm5719-llvm-6a23af0f338acaa9c1665c0a34d231f2b1574898.zip
Avoid Shadowing warnings in the associative containers tests. Thanks to STL for the patch.
llvm-svn: 272018
-rw-r--r--libcxx/test/std/containers/associative/map/map.special/non_member_swap.pass.cpp4
-rw-r--r--libcxx/test/std/containers/associative/multimap/multimap.special/non_member_swap.pass.cpp4
-rw-r--r--libcxx/test/std/containers/associative/multiset/multiset.special/non_member_swap.pass.cpp2
-rw-r--r--libcxx/test/std/containers/associative/set/set.special/non_member_swap.pass.cpp2
4 files changed, 8 insertions, 4 deletions
diff --git a/libcxx/test/std/containers/associative/map/map.special/non_member_swap.pass.cpp b/libcxx/test/std/containers/associative/map/map.special/non_member_swap.pass.cpp
index b042a4878f8..5aad163df07 100644
--- a/libcxx/test/std/containers/associative/map/map.special/non_member_swap.pass.cpp
+++ b/libcxx/test/std/containers/associative/map/map.special/non_member_swap.pass.cpp
@@ -98,6 +98,7 @@ int main()
assert(m1 == m2_save);
assert(m2 == m1_save);
}
+ }
{
typedef test_allocator<V> A;
typedef test_compare<std::less<int> > C;
@@ -166,7 +167,6 @@ int main()
assert(m2.key_comp() == C(1));
assert(m2.get_allocator() == A(1));
}
- }
#if __cplusplus >= 201103L
{
typedef std::map<int, double, std::less<int>, min_allocator<V>> M;
@@ -242,6 +242,7 @@ int main()
assert(m1 == m2_save);
assert(m2 == m1_save);
}
+ }
{
typedef min_allocator<V> A;
typedef test_compare<std::less<int> > C;
@@ -276,6 +277,5 @@ int main()
assert(m2.key_comp() == C(1));
assert(m2.get_allocator() == A());
}
- }
#endif
}
diff --git a/libcxx/test/std/containers/associative/multimap/multimap.special/non_member_swap.pass.cpp b/libcxx/test/std/containers/associative/multimap/multimap.special/non_member_swap.pass.cpp
index a91dfebb14a..eb14e19b49a 100644
--- a/libcxx/test/std/containers/associative/multimap/multimap.special/non_member_swap.pass.cpp
+++ b/libcxx/test/std/containers/associative/multimap/multimap.special/non_member_swap.pass.cpp
@@ -98,6 +98,7 @@ int main()
assert(m1 == m2_save);
assert(m2 == m1_save);
}
+ }
{
typedef test_allocator<V> A;
typedef test_compare<std::less<int> > C;
@@ -166,7 +167,6 @@ int main()
assert(m2.key_comp() == C(1));
assert(m2.get_allocator() == A(1));
}
- }
#if __cplusplus >= 201103L
{
typedef std::multimap<int, double, std::less<int>, min_allocator<std::pair<const int, double>>> M;
@@ -242,6 +242,7 @@ int main()
assert(m1 == m2_save);
assert(m2 == m1_save);
}
+ }
{
typedef min_allocator<V> A;
typedef test_compare<std::less<int> > C;
@@ -276,6 +277,5 @@ int main()
assert(m2.key_comp() == C(1));
assert(m2.get_allocator() == A());
}
- }
#endif
}
diff --git a/libcxx/test/std/containers/associative/multiset/multiset.special/non_member_swap.pass.cpp b/libcxx/test/std/containers/associative/multiset/multiset.special/non_member_swap.pass.cpp
index f456de7f624..91ec4ce93a2 100644
--- a/libcxx/test/std/containers/associative/multiset/multiset.special/non_member_swap.pass.cpp
+++ b/libcxx/test/std/containers/associative/multiset/multiset.special/non_member_swap.pass.cpp
@@ -21,6 +21,7 @@
int main()
{
typedef int V;
+ {
typedef std::multiset<int> M;
{
M m1;
@@ -94,6 +95,7 @@ int main()
assert(m1 == m2_save);
assert(m2 == m1_save);
}
+ }
{
typedef test_allocator<V> A;
typedef test_compare<std::less<int> > C;
diff --git a/libcxx/test/std/containers/associative/set/set.special/non_member_swap.pass.cpp b/libcxx/test/std/containers/associative/set/set.special/non_member_swap.pass.cpp
index 0ac14464c70..3d2d7d7d3bb 100644
--- a/libcxx/test/std/containers/associative/set/set.special/non_member_swap.pass.cpp
+++ b/libcxx/test/std/containers/associative/set/set.special/non_member_swap.pass.cpp
@@ -21,6 +21,7 @@
int main()
{
typedef int V;
+ {
typedef std::set<int> M;
{
M m1;
@@ -94,6 +95,7 @@ int main()
assert(m1 == m2_save);
assert(m2 == m1_save);
}
+ }
{
typedef test_allocator<V> A;
typedef test_compare<std::less<int> > C;
OpenPOWER on IntegriCloud