1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-27 08:38:07 +00:00

Use const() for protobuf definitions

This commit is contained in:
slush0 2016-10-03 15:41:15 +02:00
parent 8eff4fcddf
commit f5d2007297

View File

@ -12,9 +12,9 @@ def process_type(t, cls, msg_id, indexfile):
out = ["t = p.MessageType('%s')" % t, ]
if msg_id is not None:
out.append("t.wire_type = %d" % msg_id)
out.append("t.wire_type = const(%d)" % msg_id)
if indexfile is not None:
indexfile.write("%s = %d\n" % (t, msg_id))
indexfile.write("%s = const(%d)\n" % (t, msg_id))
print(" * type %s" % t)