[clang] 36fde81 - Fix failing test bots from df46fb40557a14807dd508af32251ceb1cab8b86
Aaron Ballman via cfe-commits
cfe-commits at lists.llvm.org
Sat May 21 13:10:46 PDT 2022
Author: Aaron Ballman
Date: 2022-05-21T16:10:37-04:00
New Revision: 36fde81f93606cfa6357e6463571c0222e7e6e28
URL: https://github.com/llvm/llvm-project/commit/36fde81f93606cfa6357e6463571c0222e7e6e28
DIFF: https://github.com/llvm/llvm-project/commit/36fde81f93606cfa6357e6463571c0222e7e6e28.diff
LOG: Fix failing test bots from df46fb40557a14807dd508af32251ceb1cab8b86
Should fix bots like:
https://lab.llvm.org/buildbot/#/builders/188/builds/14403
https://lab.llvm.org/buildbot/#/builders/171/builds/14928
https://lab.llvm.org/buildbot/#/builders/123/builds/10852
(and others)
Added:
Modified:
clang/test/C/drs/dr011.c
clang/test/C/drs/dr0xx.c
Removed:
################################################################################
diff --git a/clang/test/C/drs/dr011.c b/clang/test/C/drs/dr011.c
index 6bb7d4785cfa..da5695651662 100644
--- a/clang/test/C/drs/dr011.c
+++ b/clang/test/C/drs/dr011.c
@@ -14,5 +14,5 @@
int i[10];
int j[];
-// CHECK: @i = {{.*}} global [10 x i32] zeroinitializer
-// CHECK-NEXT: @j = {{.*}} global [1 x i32] zeroinitializer
+// CHECK: @i = {{.*}}global [10 x i32] zeroinitializer
+// CHECK-NEXT: @j = {{.*}}global [1 x i32] zeroinitializer
diff --git a/clang/test/C/drs/dr0xx.c b/clang/test/C/drs/dr0xx.c
index cac8b62483ac..4046765fa97e 100644
--- a/clang/test/C/drs/dr0xx.c
+++ b/clang/test/C/drs/dr0xx.c
@@ -147,7 +147,13 @@ _Static_assert(__builtin_types_compatible_p(struct S { int a; }, union U { int a
void dr031(int i) {
switch (i) {
case __INT_MAX__ + 1: break; /* expected-warning {{overflow in expression; result is -2147483648 with type 'int'}} */
+ #pragma clang diagnostic push
+ #pragma clang diagnostic ignored "-Wswitch"
+ /* Silence the targets which issue:
+ * warning: overflow converting case value to switch condition type (2147483649 to 18446744071562067969)
+ */
case __INT_MAX__ + 2ul: break;
+ #pragma clang diagnostic pop
case (__INT_MAX__ * 4) / 4: break; /* expected-warning {{overflow in expression; result is -4 with type 'int'}} */
}
}
@@ -158,4 +164,4 @@ void dr031(int i) {
* This should issue a diagnostic because a constant-expression is a
* conditional-expression, which excludes the comma operator.
*/
-int dr032 = (1, 2);
+int dr032 = (1, 2); /* expected-warning {{left operand of comma operator has no effect}} */
More information about the cfe-commits
mailing list