Fix warning with -Wsign-compare -Wsystem-headers
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / pr16286.c
blob790b6409fbcd23dbd6497144763ee9b859fc9501
1 /* { dg-do compile { target powerpc*-*-* } } */
2 /* { dg-require-effective-target powerpc_altivec_ok } */
3 /* { dg-options "-maltivec" } */
5 /* PR 16286
6 Compilation of a simple Altivec test program fails if vector, pixel
7 and/or bool are #undefined when compiling with -maltivec. This may be
8 done for building C++ programs that use the STL <vector>. */
10 #include <altivec.h>
11 #undef vector
12 #undef pixel
13 #undef bool
15 void test(void)
17 __vector unsigned int a, b;
18 __vector __pixel v0;
19 __vector __bool v1;
21 a = vec_and(a, b);
22 vec_step (b);
25 /* { dg-bogus "(syntax|parse) error before \"vector\"" "-maltivec" { target powerpc*-*-* } 0 } */
26 /* { dg-bogus "(syntax|parse) error before \"pixel\"" "-maltivec" { target powerpc*-*-* } 0 } */
27 /* { dg-bogus "(syntax|parse) error before \"bool\"" "-maltivec" { target powerpc*-*-* } 0 } */