Skip analyzer strndup test on hppa*-*-hpux*
[official-gcc.git] / gcc / testsuite / gcc.dg / Walloc-size-2.c
blobde641a689de85cc974c71d47ffdc4975b77678ea
1 /* Test that VLA types do not crash with -Walloc-size
2 { dg-do compile }
3 { dg-options "-Walloc-size" }
4 * */
6 struct foo { int x[10]; };
8 void fo0(int n)
10 struct foo (*p)[n] = __builtin_malloc(sizeof *p);
13 void fo1(int n)
15 struct bar { int x[n]; };
16 struct bar *p = __builtin_malloc(sizeof *p);