Mercurial > projects > dang
diff dang/compiler.d @ 51:c96cdcbdb9d6 new_gen
Rearranged some stuff, and renamed LLVMGen -> CodeGen
author | Anders Halager <halager@gmail.com> |
---|---|
date | Sat, 26 Apr 2008 15:54:54 +0200 |
parents | e24515bcd4ef |
children | 4ae365eff712 |
line wrap: on
line diff
--- a/dang/compiler.d Sat Apr 26 15:31:20 2008 +0200 +++ b/dang/compiler.d Sat Apr 26 15:54:54 2008 +0200 @@ -14,10 +14,10 @@ import tools.AstPrinter, tools.DotPrinter; -import gen.LuaGen, - gen.LLVMGen; +import gen.CodeGen; import sema.Visitor, + sema.AstAction, sema.SymbolTableBuilder, sema.Declarations; @@ -107,7 +107,7 @@ ["--gen-llvm"], { /* postParse.attach( (Decl[] decls, DataSource src) { - auto llvmGen = new LLVMGen(); + auto llvmGen = new CodeGen(); llvmGen.gen(decls); }); */ } @@ -140,7 +140,7 @@ postParse.attach( (Decl[] decls, DataSource src) { - auto llvmGen = new LLVMGen(); + auto llvmGen = new CodeGen(); llvmGen.gen(decls, optimize, inline); }); @@ -164,7 +164,7 @@ preParse(lexer); auto parser = new Parser; - auto decls = cast(Decl[])parser.parse(lexer); + auto decls = cast(Decl[])parser.parse(lexer, new AstAction); (new SymbolTableBuilder).visit(decls); (new Declarations).visit(decls);