comparison tests/code/if_4.d @ 24:2d28b21faad6 new_gen

New codegen! Rewritten codegen to use the llvm bindings Everything except struct are back to normal, and there a a few additions. 1. Correct code in more cases, return at the end of a while/if wont generate a "ret" followed by a "br". 2. Better scope, "int x = x" now illegal 3. Probably more
author Anders Halager <halager@gmail.com>
date Sat, 19 Apr 2008 18:29:42 +0200
parents
children
comparison
equal deleted inserted replaced
23:dd18654b5131 24:2d28b21faad6
1 int main()
2 {
3 int x = 0;
4 int y = 1;
5 if (x)
6 return 1;
7 else if (y == 2)
8 return 1;
9 else
10 y = 0;
11 return y;
12 }
13