blob: cc88cef0dcdfe8298fb87a01a80f7e0807a5217f [file] [log] [blame]
Daniel Dunbar4fcfde42009-11-08 01:45:36 +00001// RUN: clang-cc -triple i386-unknown-unknown %s -emit-llvm -o %t
2// RUN: grep "{ i8\* null, i32 1024 }" %t
Anders Carlsson8dca3b32009-07-27 05:54:15 +00003// RUN: grep "i32 0, i32 22" %t
Nuno Lopes5b2c6d92009-01-30 12:58:18 +00004
Douglas Gregor3498bdb2009-01-29 17:44:32 +00005struct foo {
6 void *a;
7 int b;
8};
9
10union { int i; float f; } u = { };
11
12int main(int argc, char **argv)
13{
14 union { int i; float f; } u2 = { };
15 static struct foo foo = {
16 .b = 1024,
17 };
18}
Douglas Gregor68c56de2009-03-27 23:40:29 +000019
20int b[2] = {
21 [1] 22
22};