summaryrefslogtreecommitdiff
path: root/test/CFrontend/2003-10-09-UnionInitializerBug.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/CFrontend/2003-10-09-UnionInitializerBug.c')
-rw-r--r--test/CFrontend/2003-10-09-UnionInitializerBug.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/CFrontend/2003-10-09-UnionInitializerBug.c b/test/CFrontend/2003-10-09-UnionInitializerBug.c
new file mode 100644
index 0000000000..e574a1931d
--- /dev/null
+++ b/test/CFrontend/2003-10-09-UnionInitializerBug.c
@@ -0,0 +1,15 @@
+struct Foo {
+ unsigned a;
+ unsigned b;
+ unsigned c;
+};
+
+struct Bar {
+ union {
+ void **a;
+ struct Foo b;
+ }u;
+};
+
+struct Bar test = {0};
+