gcc/testsuite/g++.target/powerpc/altivec-16.C
raw| 1 | // PR c++/36662 |
| 2 | // { dg-do compile } |
| 3 | // { dg-options "-maltivec" } |
| 4 | // { dg-require-effective-target powerpc_altivec } |
| 5 | |
| 6 | #define vector __attribute__((altivec (vector__))) |
| 7 | |
| 8 | template <typename c> struct S {}; |
| 9 | |
| 10 | template <> struct S<vector float> |
| 11 | { |
| 12 | static vector float zero; |
| 13 | }; |
| 14 | |
| 15 | template <int> |
| 16 | void g (void) |
| 17 | { |
| 18 | vector float t = S<vector float>::zero; |
| 19 | } |