[libcxx-commits] [libcxx] c49a13a - [libc++] Fix atomic test for _BitInt
Louis Dionne via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Dec 7 04:30:19 PST 2021
Author: Louis Dionne
Date: 2021-12-07T07:30:09-05:00
New Revision: c49a13a45a0fe965360ac399613669b9b19292ca
URL: https://github.com/llvm/llvm-project/commit/c49a13a45a0fe965360ac399613669b9b19292ca
DIFF: https://github.com/llvm/llvm-project/commit/c49a13a45a0fe965360ac399613669b9b19292ca.diff
LOG: [libc++] Fix atomic test for _BitInt
In 6c75ab5f66b4, Clang deprecated _ExtInt in favor of _BitInt, which
made this test fail. This patch disables the test on older compilers
and uses the new _BitInt type instead.
Differential Revision: https://reviews.llvm.org/D115194
Added:
libcxx/test/libcxx/atomics/bit-int.verify.cpp
Modified:
Removed:
libcxx/test/libcxx/atomics/ext-int.verify.cpp
################################################################################
diff --git a/libcxx/test/libcxx/atomics/ext-int.verify.cpp b/libcxx/test/libcxx/atomics/bit-int.verify.cpp
similarity index 69%
rename from libcxx/test/libcxx/atomics/ext-int.verify.cpp
rename to libcxx/test/libcxx/atomics/bit-int.verify.cpp
index e1aaf67edb434..3720376afa4d6 100644
--- a/libcxx/test/libcxx/atomics/ext-int.verify.cpp
+++ b/libcxx/test/libcxx/atomics/bit-int.verify.cpp
@@ -8,11 +8,13 @@
// <atomic>
-// Make sure that `std::atomic` doesn't work with `_ExtInt`. The intent is to
+// Make sure that `std::atomic` doesn't work with `_BitInt`. The intent is to
// disable them for now until their behavior can be designed better later.
// See https://reviews.llvm.org/D84049 for details.
-// UNSUPPORTED: apple-clang-12
+// TODO(ldionne): Re-enable the test on clang-14 once 6c75ab5f66b4 lands in the CI.
+// UNSUPPORTED: apple-clang-12, apple-clang-13
+// UNSUPPORTED: clang-12, clang-13, clang-14
// UNSUPPORTED: c++03
@@ -20,8 +22,8 @@
int main(int, char**)
{
- // expected-error at atomic:*1 {{_Atomic cannot be applied to integer type '_ExtInt(32)'}}
- std::atomic<_ExtInt(32)> x(42);
+ // expected-error at atomic:*1 {{_Atomic cannot be applied to integer type '_BitInt(32)'}}
+ std::atomic<_BitInt(32)> x(42);
return 0;
}
More information about the libcxx-commits
mailing list