+11
−26
Loading
These two methods are now close enough that we can finally merge them, relying on the fact that simple unions now provide a reasonable local_members. Change gen_struct() to gen_object() that handles all forms of QAPISchemaObjectType, and rename and shrink gen_union() to gen_variants() to handle the portion of gen_object() needed when variants are present. gen_struct_fields() now has a single caller, so it no longer needs an optional parameter; however, I did not choose to inline it into the caller. No difference to generated code. Signed-off-by:Eric Blake <eblake@redhat.com> Message-Id: <1447836791-369-3-git-send-email-eblake@redhat.com> Signed-off-by:
Markus Armbruster <armbru@redhat.com>