summaryrefslogtreecommitdiffstats
path: root/test/Parser/altivec.c
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2012-08-15 20:02:54 +0000
committerdim <dim@FreeBSD.org>2012-08-15 20:02:54 +0000
commit554bcb69c2d785a011a30e7db87a36a87fe7db10 (patch)
tree9abb1a658a297776086f4e0dfa6ca533de02104e /test/Parser/altivec.c
parentbb67ca86b31f67faee50bd10c3b036d65751745a (diff)
downloadFreeBSD-src-554bcb69c2d785a011a30e7db87a36a87fe7db10.zip
FreeBSD-src-554bcb69c2d785a011a30e7db87a36a87fe7db10.tar.gz
Vendor import of clang trunk r161861:
http://llvm.org/svn/llvm-project/cfe/trunk@161861
Diffstat (limited to 'test/Parser/altivec.c')
-rw-r--r--test/Parser/altivec.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/Parser/altivec.c b/test/Parser/altivec.c
index d1e6552..0bdc3dc 100644
--- a/test/Parser/altivec.c
+++ b/test/Parser/altivec.c
@@ -76,6 +76,16 @@ vector bool unsigned int v_bsc2; // expected-error {{cannot use 'unsigned' w
vector bool long v_bl; // expected-error {{cannot use 'long' with '__vector bool'}}
vector bool long long v_bll; // expected-error {{cannot use 'long long' with '__vector bool'}}
+typedef char i8;
+typedef short i16;
+typedef int i32;
+struct S {
+ // i8, i16, i32 here are field names, not type names.
+ vector bool i8; // expected-error {{requires a specifier or qualifier}}
+ vector pixel i16;
+ vector long i32; // expected-warning {{deprecated}}
+};
+
void f() {
__vector unsigned int v = {0,0,0,0};
__vector int v__cast = (__vector int)v;
OpenPOWER on IntegriCloud