cgen: remove the checker

pull/3635/head^2
Alexander Medvednikov 2020-02-03 11:36:03 +01:00
parent 40fd918b58
commit 01f45f063e
1 changed files with 0 additions and 5 deletions

View File

@ -4,7 +4,6 @@ import (
strings strings
v.ast v.ast
v.table v.table
v.checker
term term
) )
@ -12,7 +11,6 @@ struct Gen {
out strings.Builder out strings.Builder
definitions strings.Builder // typedefs, defines etc (everything that goes to the top of the file) definitions strings.Builder // typedefs, defines etc (everything that goes to the top of the file)
table &table.Table table &table.Table
checker checker.Checker
mut: mut:
fn_decl &ast.FnDecl // pointer to the FnDecl we are currently inside otherwise 0 fn_decl &ast.FnDecl // pointer to the FnDecl we are currently inside otherwise 0
} }
@ -23,8 +21,6 @@ pub fn cgen(files []ast.File, table &table.Table) string {
out: strings.new_builder(100) out: strings.new_builder(100)
definitions: strings.new_builder(100) definitions: strings.new_builder(100)
table: table table: table
checker: checker.new_checker(table) // checker
fn_decl: 0 fn_decl: 0
} }
for file in files { for file in files {
@ -116,7 +112,6 @@ fn (g mut Gen) stmt(node ast.Stmt) {
g.writeln(';') g.writeln(';')
} }
ast.VarDecl { ast.VarDecl {
mut typ := it.typ
g.write('$it.typ.name $it.name = ') g.write('$it.typ.name $it.name = ')
g.expr(it.expr) g.expr(it.expr)
g.writeln(';') g.writeln(';')