diff --git a/test/pmr/test_pmr_allocator.cpp b/test/pmr/test_pmr_allocator.cpp index d90abf9..266e23c 100644 --- a/test/pmr/test_pmr_allocator.cpp +++ b/test/pmr/test_pmr_allocator.cpp @@ -1,6 +1,8 @@ #include +#if defined(LIBIMP_CPP_17) && defined(__cpp_lib_memory_resource) #include +#endif #include "gtest/gtest.h" @@ -11,8 +13,10 @@ TEST(allocator, detail) { EXPECT_FALSE(pmr::detail::has_allocate::value); EXPECT_FALSE(pmr::detail::has_allocate>::value); EXPECT_TRUE (pmr::detail::has_allocate>::value); +#if defined(LIBIMP_CPP_17) && defined(__cpp_lib_memory_resource) EXPECT_TRUE (pmr::detail::has_allocate::value); EXPECT_TRUE (pmr::detail::has_allocate>::value); +#endif } TEST(allocator, construct) {