1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00
This commit is contained in:
Alexander Medvednikov 2020-02-21 18:15:41 +01:00
parent 4c95e59d5c
commit 1d90c1cbbf

View File

@ -195,10 +195,9 @@ fn (f mut Fmt) struct_decl(node ast.StructDecl) {
}
}
for field in node.fields {
field_type_sym := f.table.get_type_symbol(field.typ)
f.write('\t$field.name ')
f.write(strings.repeat(` `, max - field.name.len))
f.writeln('$field_type_sym.name')
f.writeln(f.table.type_to_str(field.typ))
}
f.writeln('}\n')
}