From fed691abddc2b242a6bcb81d87e18797b95bbe80 Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Tue, 7 Mar 2017 16:15:51 +0000 Subject: Can compile simplest program --- c_compiler/test/in/02.c | 4 ++++ c_compiler/test/in/03.c | 5 +++++ c_compiler/test/in/04.c | 9 +++++++++ 3 files changed, 18 insertions(+) create mode 100644 c_compiler/test/in/02.c create mode 100644 c_compiler/test/in/03.c create mode 100644 c_compiler/test/in/04.c (limited to 'c_compiler/test/in') diff --git a/c_compiler/test/in/02.c b/c_compiler/test/in/02.c new file mode 100644 index 0000000..95c954c --- /dev/null +++ b/c_compiler/test/in/02.c @@ -0,0 +1,4 @@ +int main() { + int x = 26; + return x; +} diff --git a/c_compiler/test/in/03.c b/c_compiler/test/in/03.c new file mode 100644 index 0000000..911f7e2 --- /dev/null +++ b/c_compiler/test/in/03.c @@ -0,0 +1,5 @@ +int main() { + int x; + x = 15; + return x; +} diff --git a/c_compiler/test/in/04.c b/c_compiler/test/in/04.c new file mode 100644 index 0000000..57cf697 --- /dev/null +++ b/c_compiler/test/in/04.c @@ -0,0 +1,9 @@ +int main() { + int a = 3; + int b = 5; + return a + b; +} + +int f(int a, int v) { + return a + v; +} -- cgit