Add integer attributes

This commit is contained in:
Arnaud Durand 2019-12-19 09:03:12 +01:00
parent f8c5821658
commit 94e239ff13
1 changed files with 2 additions and 1 deletions

View File

@ -210,7 +210,8 @@ def _printattr(attr, attr_translate):
if not firsta:
r += ", "
firsta = False
r += attr_name + " = \"" + attr_value + "\""
const_expr = "\"" + attr_value + "\"" if not isinstance(attr_value, int) else str(attr_value)
r += attr_name + " = " + const_expr
if r:
r = "(* " + r + " *)"
return r