From 82b33708bad5fa032a18c03b49fcf6b70f24b180 Mon Sep 17 00:00:00 2001 From: LeonineKing1199 Date: Tue, 7 Dec 2021 11:21:43 -0800 Subject: [PATCH] Update `allocator_traits` test to only check for inherited SOCCC when the C++11 `allocator` is present --- test/unordered/allocator_traits.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/unordered/allocator_traits.cpp b/test/unordered/allocator_traits.cpp index 0517fb97..ede48476 100644 --- a/test/unordered/allocator_traits.cpp +++ b/test/unordered/allocator_traits.cpp @@ -213,7 +213,15 @@ void test_allocator2() BOOST_TEST(!traits::propagate_on_container_move_assignment::value); BOOST_TEST(!traits::propagate_on_container_swap::value); BOOST_TEST(!traits::is_always_equal::value); + +#if !defined(BOOST_NO_CXX11_ALLOCATOR) + // conditionally compile this assertion as all C++03 emulations of expression + // SFINAE are broken one way or another and the benefits of using Core's + // `allocator_traits` outweigh the costs of breaking this kind of code (i.e. + // inheriting SOCCC via a base) + // BOOST_TEST(call_select() == 1); +#endif } // allocator 3