This is my toy C compiler. When you want to play this compiler, look at test.sh
for knowing what valid syntaxes are.
$ make
$ echo 'int main() { return 0; }' | ./compiler
=> some assembly
$ echo 'int ten() { return 10;} int main() { int i; i = 3; return ten() + i; }' | ./compiler > hoge.s && gcc hoge.s && ./a.out
$ echo $?
=> 13
$ make test