aboutsummaryrefslogtreecommitdiffstats
path: root/test/CFrontend
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-07-23 18:25:39 +0000
committerChris Lattner <sabre@nondot.org>2002-07-23 18:25:39 +0000
commit3b1778bccf5779bfc121349f82b91f215b856bb4 (patch)
tree89041b05b6ff8ca5d66ec0451a0103d8f385bc45 /test/CFrontend
parent7e1635e895c4b8ae41fbb1e98ad111171d8fa1af (diff)
downloadexternal_llvm-3b1778bccf5779bfc121349f82b91f215b856bb4.zip
external_llvm-3b1778bccf5779bfc121349f82b91f215b856bb4.tar.gz
external_llvm-3b1778bccf5779bfc121349f82b91f215b856bb4.tar.bz2
Check in testcases that were just in my tree
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3023 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CFrontend')
-rw-r--r--test/CFrontend/2002-02-18-StaticData.c11
-rw-r--r--test/CFrontend/2002-04-09-StructRetVal.c10
-rw-r--r--test/CFrontend/2002-05-24-Alloca.c9
3 files changed, 30 insertions, 0 deletions
diff --git a/test/CFrontend/2002-02-18-StaticData.c b/test/CFrontend/2002-02-18-StaticData.c
new file mode 100644
index 0000000..78614a7
--- /dev/null
+++ b/test/CFrontend/2002-02-18-StaticData.c
@@ -0,0 +1,11 @@
+
+double FOO = 17;
+double BAR = 12.0;
+float XX = 12.0f;
+
+static char *procnames[] = {
+ "EXIT"
+};
+
+void *Data[] = { &FOO, &BAR, &XX };
+
diff --git a/test/CFrontend/2002-04-09-StructRetVal.c b/test/CFrontend/2002-04-09-StructRetVal.c
new file mode 100644
index 0000000..8ba8bfa
--- /dev/null
+++ b/test/CFrontend/2002-04-09-StructRetVal.c
@@ -0,0 +1,10 @@
+struct S {
+ int i;
+ short s1, s2;
+};
+
+struct S func_returning_struct(void);
+
+void loop(void) {
+ func_returning_struct();
+}
diff --git a/test/CFrontend/2002-05-24-Alloca.c b/test/CFrontend/2002-05-24-Alloca.c
new file mode 100644
index 0000000..698452e
--- /dev/null
+++ b/test/CFrontend/2002-05-24-Alloca.c
@@ -0,0 +1,9 @@
+#include <string.h>
+#include <stdio.h>
+#include <stdlib.h>
+
+int main(int argc, char **argv) {
+ char *C = (char*)alloca(argc);
+ strcpy(C, argv[0]);
+ puts(C);
+}