diff --git a/test/std/containers/sequences/deque/deque.cons/size.pass.cpp b/test/std/containers/sequences/deque/deque.cons/size.pass.cpp index c983a604e..64b3d811f 100644 --- a/test/std/containers/sequences/deque/deque.cons/size.pass.cpp +++ b/test/std/containers/sequences/deque/deque.cons/size.pass.cpp @@ -33,12 +33,12 @@ test2(unsigned n) assert(static_cast(DefaultOnly::count) == n); assert(d.size() == n); assert(static_cast(distance(d.begin(), d.end())) == d.size()); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES for (const_iterator i = d.begin(), e = d.end(); i != e; ++i) assert(*i == T()); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES } assert(DefaultOnly::count == 0); +#else + ((void)n); #endif } @@ -54,10 +54,10 @@ test1(unsigned n) assert(static_cast(DefaultOnly::count) == n); assert(d.size() == n); assert(static_cast(distance(d.begin(), d.end())) == d.size()); -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES +#if TEST_STD_VER >= 11 for (const_iterator i = d.begin(), e = d.end(); i != e; ++i) assert(*i == T()); -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES +#endif } assert(DefaultOnly::count == 0); } @@ -74,6 +74,9 @@ test3(unsigned n, Allocator const &alloc = Allocator()) assert(d.size() == n); assert(d.get_allocator() == alloc); } +#else + ((void)n); + ((void)alloc); #endif } diff --git a/test/std/containers/sequences/list/list.cons/size_type.pass.cpp b/test/std/containers/sequences/list/list.cons/size_type.pass.cpp index 6720a00cf..95cdeb0c8 100644 --- a/test/std/containers/sequences/list/list.cons/size_type.pass.cpp +++ b/test/std/containers/sequences/list/list.cons/size_type.pass.cpp @@ -32,6 +32,9 @@ test3(unsigned n, Allocator const &alloc = Allocator()) assert(static_cast(std::distance(d.begin(), d.end())) == n); assert(d.get_allocator() == alloc); } +#else + ((void)n); + ((void)alloc); #endif } @@ -76,14 +79,12 @@ int main() test3> (3); } #endif -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES +#if TEST_STD_VER >= 11 { std::list l(3); assert(l.size() == 3); assert(std::distance(l.begin(), l.end()) == 3); } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES -#if TEST_STD_VER >= 11 { std::list> l(3); assert(l.size() == 3); @@ -95,12 +96,10 @@ int main() ++i; assert(*i == 0); } -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES { std::list> l(3); assert(l.size() == 3); assert(std::distance(l.begin(), l.end()) == 3); } -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES #endif } diff --git a/test/std/containers/sequences/vector.bool/construct_size.pass.cpp b/test/std/containers/sequences/vector.bool/construct_size.pass.cpp index 271e4ee33..1fb86a24a 100644 --- a/test/std/containers/sequences/vector.bool/construct_size.pass.cpp +++ b/test/std/containers/sequences/vector.bool/construct_size.pass.cpp @@ -31,6 +31,9 @@ test2(typename C::size_type n, assert(c.get_allocator() == a); for (typename C::const_iterator i = c.cbegin(), e = c.cend(); i != e; ++i) assert(*i == typename C::value_type()); +#else + ((void)n); + ((void)a); #endif } diff --git a/test/std/containers/sequences/vector/vector.cons/construct_size.pass.cpp b/test/std/containers/sequences/vector/vector.cons/construct_size.pass.cpp index 46e5ecdc9..7416a6ac9 100644 --- a/test/std/containers/sequences/vector/vector.cons/construct_size.pass.cpp +++ b/test/std/containers/sequences/vector/vector.cons/construct_size.pass.cpp @@ -32,6 +32,9 @@ test2(typename C::size_type n, typename C::allocator_type const& a = typename C: LIBCPP_ASSERT(is_contiguous_container_asan_correct(c)); for (typename C::const_iterator i = c.cbegin(), e = c.cend(); i != e; ++i) assert(*i == typename C::value_type()); +#else + ((void)n); + ((void)a); #endif } diff --git a/test/std/containers/unord/unord.multimap/unord.multimap.cnstr/move.pass.cpp b/test/std/containers/unord/unord.multimap/unord.multimap.cnstr/move.pass.cpp index cc4e32e83..df69b5287 100644 --- a/test/std/containers/unord/unord.multimap/unord.multimap.cnstr/move.pass.cpp +++ b/test/std/containers/unord/unord.multimap/unord.multimap.cnstr/move.pass.cpp @@ -7,6 +7,8 @@ // //===----------------------------------------------------------------------===// +// UNSUPPORTED: c++98, c++03 + // // template , class Pred = equal_to, @@ -30,23 +32,13 @@ int main() { -#ifndef _LIBCPP_HAS_NO_RVALUE_REFERENCES { typedef std::unordered_multimap >, test_compare >, test_allocator > > C; - typedef std::pair P; - P a[] = - { - P(1, "one"), - P(2, "two"), - P(3, "three"), - P(4, "four"), - P(1, "four"), - P(2, "four"), - }; + C c0(7, test_hash >(8), test_compare >(9), @@ -130,23 +122,12 @@ int main() assert(c0.empty()); } -#if TEST_STD_VER >= 11 { typedef std::unordered_multimap >, test_compare >, min_allocator > > C; - typedef std::pair P; - P a[] = - { - P(1, "one"), - P(2, "two"), - P(3, "three"), - P(4, "four"), - P(1, "four"), - P(2, "four"), - }; C c0(7, test_hash >(8), test_compare >(9), @@ -230,7 +211,6 @@ int main() assert(c0.empty()); } -#endif #if _LIBCPP_DEBUG >= 1 { std::unordered_multimap s1 = {{1, 1}, {2, 2}, {3, 3}}; @@ -242,5 +222,4 @@ int main() assert(s2.size() == 2); } #endif -#endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES } diff --git a/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp b/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp index cf9339341..cdd163980 100644 --- a/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp +++ b/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp @@ -26226,25 +26226,25 @@ int main() std::locale lg(lc, new my_numpunct); const my_facet f(1); { - long double v = -INFINITY; + long double v = -INFINITY; ((void)v); } { - long double v = std::nan(""); + long double v = std::nan(""); ((void)v); } { - long double v = +0.; + long double v = +0.; ((void)v); } { - long double v = -INFINITY; + long double v = -INFINITY; ((void)v); } { - long double v = std::nan(""); + long double v = std::nan(""); ((void)v); } { - long double v = -INFINITY; + long double v = -INFINITY; ((void)v); } { - long double v = std::nan(""); + long double v = std::nan(""); ((void)v); } } diff --git a/test/std/re/re.submatch/re.submatch.members/compare_string_type.pass.cpp b/test/std/re/re.submatch/re.submatch.members/compare_string_type.pass.cpp index be05afd4c..1634c5a39 100644 --- a/test/std/re/re.submatch/re.submatch.members/compare_string_type.pass.cpp +++ b/test/std/re/re.submatch/re.submatch.members/compare_string_type.pass.cpp @@ -24,7 +24,6 @@ int main() typedef std::sub_match SM; typedef SM::string_type string; SM sm = SM(); - SM sm2 = SM(); assert(sm.compare(string()) == 0); const CharT s[] = {'1', '2', '3', 0}; sm.first = s; @@ -38,7 +37,6 @@ int main() typedef std::sub_match SM; typedef SM::string_type string; SM sm = SM(); - SM sm2 = SM(); assert(sm.compare(string()) == 0); const CharT s[] = {'1', '2', '3', 0}; sm.first = s; diff --git a/test/std/re/re.submatch/re.submatch.members/compare_value_type_ptr.pass.cpp b/test/std/re/re.submatch/re.submatch.members/compare_value_type_ptr.pass.cpp index 097a3918e..5e2ea8fb5 100644 --- a/test/std/re/re.submatch/re.submatch.members/compare_value_type_ptr.pass.cpp +++ b/test/std/re/re.submatch/re.submatch.members/compare_value_type_ptr.pass.cpp @@ -23,7 +23,6 @@ int main() typedef char CharT; typedef std::sub_match SM; SM sm = SM(); - SM sm2 = SM(); assert(sm.compare("") == 0); const CharT s[] = {'1', '2', '3', 0}; sm.first = s; @@ -36,7 +35,6 @@ int main() typedef wchar_t CharT; typedef std::sub_match SM; SM sm = SM(); - SM sm2 = SM(); assert(sm.compare(L"") == 0); const CharT s[] = {'1', '2', '3', 0}; sm.first = s;