autofree: free strings

pull/2047/head
Alexander Medvednikov 2019-09-19 14:01:02 +03:00
parent 486b3d2f92
commit f629069572
2 changed files with 4 additions and 1 deletions

View File

@ -193,6 +193,9 @@ fn main() {
v.cgen.lines.free()
free(v.cgen)
free(v.table)
//for p in parsers {
//}
println('done!')
}
}

View File

@ -1078,7 +1078,7 @@ fn (p mut Parser) close_scope() {
free_fn = 'v_array_free'
} else if v.typ == 'string' {
free_fn = 'v_string_free'
continue
//continue
} else if v.ptr || v.typ.ends_with('*') {
free_fn = 'v_ptr_free'
//continue