Merge -r 127928:132243 from trunk
[official-gcc.git] / gcc / testsuite / g++.dg / ext / tmplattr4.C
blob3d5c6b7d5fbd718767521669b0320a72c9333519
1 // PR c++/7586
2 // { dg-do run }
4 template<typename T>
5 int f()
7   typedef unsigned char type[sizeof (T)]
8     __attribute((aligned(__alignof(T))));
10   return __alignof (type);
13 int main()
15   if (f<int>() == __alignof (int))
16     return 0;
17   else
18     return 1;