Skip to content

Commit 892af90

Browse files
committed
TEST_STD_VER >= 23 || !TEST_IS_CONSTANT_EVALUATED instead of !TEST_IS_CONSTANT_EVALUATED || TEST_STD_VER >= 23
1 parent 6bcf548 commit 892af90

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

libcxx/test/std/algorithms/alg.modifying.operations/alg.swap/swap_ranges.pass.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ TEST_CONSTEXPR_CXX20 bool test() {
126126

127127
#if TEST_STD_VER >= 11
128128
// We can't test unique_ptr in constant evaluation before C++23 as it's constexpr only since C++23.
129-
if (!TEST_IS_CONSTANT_EVALUATED || TEST_STD_VER >= 23)
129+
if (TEST_STD_VER >= 23 || !TEST_IS_CONSTANT_EVALUATED)
130130
types::for_each(types::forward_iterator_list<std::unique_ptr<int>*>(), TestUniquePtr());
131131
#endif
132132

libcxx/test/std/utilities/utility/utility.swap/swap_array.pass.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ TEST_CONSTEXPR_CXX20 bool test() {
122122
}
123123

124124
// We can't test unique_ptr in constant evaluation before C++23 as it's constexpr only since C++23.
125-
if (!TEST_IS_CONSTANT_EVALUATED || TEST_STD_VER >= 23) {
125+
if (TEST_STD_VER >= 23 || !TEST_IS_CONSTANT_EVALUATED) {
126126
std::unique_ptr<int> i[3];
127127
for (int k = 0; k < 3; ++k)
128128
i[k].reset(new int(k + 1));

0 commit comments

Comments
 (0)