diff options
-rw-r--r-- | test/CFrontend/2006-10-30-ArrayCrash.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/CFrontend/2006-10-30-ArrayCrash.c b/test/CFrontend/2006-10-30-ArrayCrash.c new file mode 100644 index 0000000000..b0663c1f1f --- /dev/null +++ b/test/CFrontend/2006-10-30-ArrayCrash.c @@ -0,0 +1,16 @@ +// RUN: %llvmgcc -O3 -S -o - %s + +extern void foo(); + +struct S { + short f1[3]; + unsigned int f2 : 1; +}; + +void bar() +{ + struct S *A; + + if (A->f2) + foo(); +} |