Skip to content

Commit 07fdc08

Browse files
committed
[libc++] Add missing check for C++17 in test
This was never caught on our bots because this specific test is marked as `XFAIL: !is-lockfree-runtime-function`, which is the case on our bots.
1 parent 0401668 commit 07fdc08

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

libcxx/test/std/atomics/atomics.types.operations/atomics.types.operations.req/atomic_is_lock_free.pass.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,10 @@ struct TestFn {
3030

3131
A a(t);
3232
bool b1 = std::atomic_is_lock_free(static_cast<const A*>(&a));
33+
#if TEST_STD_VER >= 17
3334
if (A::is_always_lock_free)
3435
assert(b1);
36+
#endif
3537

3638
volatile A va(t);
3739
bool b2 = std::atomic_is_lock_free(static_cast<const volatile A*>(&va));

0 commit comments

Comments
 (0)