summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2016-12-24 01:29:27 +0000
committerEric Fiselier <eric@efcs.ca>2016-12-24 01:29:27 +0000
commit2bc3471d409e4d38194a5284da85bc54e672f3e4 (patch)
tree99a6c2cfcc52d2646e45beb265dd2a2036cd0356
parenta3f141113ef83c5de82ce1fb84dd6be324880153 (diff)
downloadbcm5719-llvm-2bc3471d409e4d38194a5284da85bc54e672f3e4.tar.gz
bcm5719-llvm-2bc3471d409e4d38194a5284da85bc54e672f3e4.zip
Fix yet another missed -Wunused warning. Hopefully this is the last one
llvm-svn: 290476
-rw-r--r--libcxx/test/std/containers/sequences/forwardlist/forwardlist.cons/size.pass.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/libcxx/test/std/containers/sequences/forwardlist/forwardlist.cons/size.pass.cpp b/libcxx/test/std/containers/sequences/forwardlist/forwardlist.cons/size.pass.cpp
index db40707a26e..b536ccf4910 100644
--- a/libcxx/test/std/containers/sequences/forwardlist/forwardlist.cons/size.pass.cpp
+++ b/libcxx/test/std/containers/sequences/forwardlist/forwardlist.cons/size.pass.cpp
@@ -28,6 +28,9 @@ void check_allocator(unsigned n, Allocator const &alloc = Allocator())
C d(n, alloc);
assert(d.get_allocator() == alloc);
assert(static_cast<std::size_t>(std::distance(d.begin(), d.end())) == n);
+#else
+ ((void)n);
+ ((void)alloc);
#endif
}
@@ -39,12 +42,14 @@ int main()
unsigned N = 10;
C c(N);
unsigned n = 0;
- for (C::const_iterator i = c.begin(), e = c.end(); i != e; ++i, ++n)
-#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
+
+ for (C::const_iterator i = c.begin(), e = c.end(); i != e; ++i, ++n) {
+#if TEST_STD_VER >= 11
assert(*i == T());
#else
- ;
+ ((void)0);
#endif
+ }
assert(n == N);
}
#if TEST_STD_VER >= 11
@@ -55,11 +60,7 @@ int main()
C c(N);
unsigned n = 0;
for (C::const_iterator i = c.begin(), e = c.end(); i != e; ++i, ++n)
-#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES
assert(*i == T());
-#else
- ;
-#endif
assert(n == N);
check_allocator<T, min_allocator<T>> ( 0 );
check_allocator<T, min_allocator<T>> ( 3 );
OpenPOWER on IntegriCloud