mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice-protocol
synced 2025-12-26 22:55:30 +00:00
codegen: ifdef/endif function declaration too
Compile out part that we are not supporting. In the future, we might want to declare a fake type and an empty function to keep API compatibility
This commit is contained in:
parent
055c68ccdd
commit
3215ddd6cd
@ -378,6 +378,7 @@ def write_protocol_marshaller(writer, proto, is_server, private_marshallers):
|
||||
channel = c.channel_type
|
||||
if channel.has_attr("ifdef"):
|
||||
writer.ifdef(channel.attributes["ifdef"][0])
|
||||
writer.header.ifdef(channel.attributes["ifdef"][0])
|
||||
if is_server:
|
||||
for m in channel.client_messages:
|
||||
message = m.message_type
|
||||
@ -400,6 +401,7 @@ def write_protocol_marshaller(writer, proto, is_server, private_marshallers):
|
||||
functions[f] = True
|
||||
if channel.has_attr("ifdef"):
|
||||
writer.endif(channel.attributes["ifdef"][0])
|
||||
writer.header.endif(channel.attributes["ifdef"][0])
|
||||
|
||||
if private_marshallers:
|
||||
scope = writer.function("spice_message_marshallers_get" + writer.public_prefix,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user