mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
fix parser tests
This commit is contained in:
parent
093a025ebf
commit
3a7f1db947
2
v2.v
2
v2.v
@ -23,7 +23,7 @@ fn main() {
|
||||
text := os.read_file(path)?
|
||||
table := &table.Table{}
|
||||
program := parser.parse_file(text, table)
|
||||
res := gen.cgen(program)
|
||||
res := gen.cgen([program])
|
||||
mut out := os.create('out.c')?
|
||||
out.writeln(cdefs)
|
||||
out.writeln(res)
|
||||
|
@ -23,7 +23,7 @@ x := 10
|
||||
'
|
||||
table := &table.Table{}
|
||||
prog := parse_file(s, table)
|
||||
res := gen.cgen(prog)
|
||||
res := gen.cgen([prog])
|
||||
println(res)
|
||||
}
|
||||
|
||||
@ -79,7 +79,7 @@ fn test_parse_expr() {
|
||||
program := ast.File{
|
||||
stmts: e
|
||||
}
|
||||
res := gen.cgen(program)
|
||||
res := gen.cgen([program])
|
||||
println('========')
|
||||
println(res)
|
||||
println('========')
|
||||
|
Loading…
Reference in New Issue
Block a user