summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/const-init.c
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2008-08-05 06:30:41 +0000
committerDaniel Dunbar <daniel@zuster.org>2008-08-05 06:30:41 +0000
commitd548c79eaff76a04b1710c4e82fb01afe653bff8 (patch)
tree8707ef1ba1128fdc7e872402276099f62931754f /clang/test/CodeGen/const-init.c
parent197a3016690474cd8440eb102bdd40590ee1bfd1 (diff)
downloadbcm5719-llvm-d548c79eaff76a04b1710c4e82fb01afe653bff8.tar.gz
bcm5719-llvm-d548c79eaff76a04b1710c4e82fb01afe653bff8.zip
Fix const-init test case
- Use -verify and added expected warnings for EXTWARN change. llvm-svn: 54342
Diffstat (limited to 'clang/test/CodeGen/const-init.c')
-rw-r--r--clang/test/CodeGen/const-init.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/test/CodeGen/const-init.c b/clang/test/CodeGen/const-init.c
index ccc34cf1368..0efab6f9036 100644
--- a/clang/test/CodeGen/const-init.c
+++ b/clang/test/CodeGen/const-init.c
@@ -1,4 +1,4 @@
-// RUN: clang -emit-llvm %s 2>&1 | not grep warning
+// RUN: clang -verify -emit-llvm -o %t %s
#include <stdint.h>
@@ -7,9 +7,9 @@ char a[] = { "asdf" };
// Double-implicit-conversions of array/functions (not legal C, but
// clang accepts it for gcc compat).
-intptr_t b = a;
+intptr_t b = a; // expected-warning {{incompatible pointer to integer conversion}}
int c();
void *d = c;
-intptr_t e = c;
+intptr_t e = c; // expected-warning {{incompatible pointer to integer conversion}}
int f, *g = __extension__ &f, *h = (1 != 1) ? &f : &f;
OpenPOWER on IntegriCloud