aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-02-17 05:44:57 +0000
committerChris Lattner <sabre@nondot.org>2007-02-17 05:44:57 +0000
commit7824cc625b51ef1183759e3cbd18445da7516490 (patch)
treed38523854a902ca33145d03f16d0c3e1c133d552 /test
parent4b0d93a7b5b5e5ad6cdf73526a0a17328dfb3e5f (diff)
downloadexternal_llvm-7824cc625b51ef1183759e3cbd18445da7516490.zip
external_llvm-7824cc625b51ef1183759e3cbd18445da7516490.tar.gz
external_llvm-7824cc625b51ef1183759e3cbd18445da7516490.tar.bz2
testcase for PR1170
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34366 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/CFrontend/2007-02-16-VariableSizeStructArg.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/CFrontend/2007-02-16-VariableSizeStructArg.c b/test/CFrontend/2007-02-16-VariableSizeStructArg.c
new file mode 100644
index 0000000..fd07cd8
--- /dev/null
+++ b/test/CFrontend/2007-02-16-VariableSizeStructArg.c
@@ -0,0 +1,7 @@
+// RUN: %llvmgcc -S %s -o -
+// PR1170
+int f(int a, struct {int b[a];} c) { return c.b[0]; }
+
+int g(struct {int b[1];} c) {
+ return c.b[0];
+}