blob: 80ca78d5cf5f1e213ca4ef85134bbf8b12790207 [file] [log] [blame]
Daniel Dunbara5728872009-12-15 20:14:24 +00001// RUN: %clang_cc1 -emit-llvm < %s | grep puts | count 4
Eli Friedman8f426fa2009-04-20 03:21:44 +00002
Eli Friedmanc62aad82009-04-20 03:54:15 +00003// PR3248
Eli Friedman8f426fa2009-04-20 03:21:44 +00004int a(int x)
5{
6 int (*y)[x];
7 return sizeof(*(puts("asdf"),y));
8}
Eli Friedmanc62aad82009-04-20 03:54:15 +00009
10// PR3247
11int b() {
12 return sizeof(*(char(*)[puts("asdf")])0);
13}
14
15// PR3247
16int c() {
17 static int (*y)[puts("asdf")];
18 return sizeof(*y);
19}