Add new test to verify that the array index, limit, and stride are
[official-gcc.git] / gcc / testsuite / gcc.dg / transparent-union-4.c
blobf661cf2cb54dc75f7bd2f6cde29799bb529ca0a8
1 /* Test for ICE on transparent union with function pointer and
2 -pedantic. Bug 22240. */
3 /* Origin: Joseph Myers <joseph@codesourcery.com> */
4 /* { dg-do compile } */
5 /* { dg-options "-pedantic" } */
7 typedef union { union w *u; int *i; } H __attribute__ ((transparent_union));
8 void (*h) (H);
9 void g (int *s) { h (s); } /* { dg-warning "ISO C prohibits argument conversion to union type" } */