projects
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
550880a
)
c++: Improve testcase [PR98332]
author
Jason Merrill
<jason@redhat.com>
Wed, 23 Dec 2020 22:06:39 +0000
(17:06 -0500)
committer
Jason Merrill
<jason@redhat.com>
Wed, 23 Dec 2020 22:08:05 +0000
(17:08 -0500)
gcc/testsuite/ChangeLog:
* g++.dg/cpp0x/constexpr-overflow3.C: Use INT_MAX.
gcc/testsuite/g++.dg/cpp0x/constexpr-overflow3.C
patch
|
blob
|
history
diff --git
a/gcc/testsuite/g++.dg/cpp0x/constexpr-overflow3.C
b/gcc/testsuite/g++.dg/cpp0x/constexpr-overflow3.C
index 22d4c59f4f8b7392735d2778aa23eb89245ef3c9..61766257e39fc0a26db4110ed9fe253b7ed70a29 100644
(file)
--- a/
gcc/testsuite/g++.dg/cpp0x/constexpr-overflow3.C
+++ b/
gcc/testsuite/g++.dg/cpp0x/constexpr-overflow3.C
@@
-1,5
+1,7
@@
// PR c++/98332
// { dg-do compile { target c++11 } }
-struct S { int a = 2147483647 + 1; }; // { dg-warning "overflow" }
+#include <limits.h>
+
+struct S { int a = INT_MAX + 1; }; // { dg-warning "overflow" }
struct { S b[2][1][1][1]; } c;