diff options
-rw-r--r-- | test/CFrontend/2005-10-18-VariableSizedElementCrash.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/CFrontend/2005-10-18-VariableSizedElementCrash.c b/test/CFrontend/2005-10-18-VariableSizedElementCrash.c new file mode 100644 index 0000000000..9efa1108ed --- /dev/null +++ b/test/CFrontend/2005-10-18-VariableSizedElementCrash.c @@ -0,0 +1,9 @@ +// RUN: %llvmgcc %s -S -o - +// XFAIL: * +int sub1(int i, char *pi) { + typedef int foo[i]; + struct bar {foo f1; int f2:3; int f3:4} *p = (struct bar *) pi; + xxx(p->f1); + return p->f3; +} + |