xref: /llvm-project/clang/test/CodeGen/variable-array.c (revision 7d644e1215b376ec5e915df9ea2eeb56e2d94626)
1 // RUN: %clang_cc1 -emit-llvm < %s | grep puts | count 4
2 
3 int puts(const char *);
4 
5 // PR3248
a(int x)6 int a(int x)
7 {
8   int (*y)[x];
9   return sizeof(*(puts("asdf"),y));
10 }
11 
12 // PR3247
b(void)13 int b(void) {
14   return sizeof(*(char(*)[puts("asdf")])0);
15 }
16 
17 // PR3247
c(void)18 int c(void) {
19   static int (*y)[puts("asdf")];
20   return sizeof(*y);
21 }
22