1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

compiler: add all C reserved words to CReserved

This commit is contained in:
Delyan Angelov
2019-08-26 20:04:57 +03:00
committed by Alexander Medvednikov
parent d88315d789
commit 99c9410cc2
2 changed files with 37 additions and 3 deletions

View File

@ -124,7 +124,7 @@ fn (p mut Parser) select_query(fn_ph int) string {
for i, field in fields {
mut cast := ''
if field.typ == 'int' {
cast = 'string_int'
cast = 'v_string_int'
}
obj_gen.writeln('${qprefix}$tmp . $field.name = $cast( *(string*)array__get(${qprefix}row.vals, $i) );')
}