qapi: Support downstream simple unions

Enhance the testsuite to cover downstream simple unions, including
when a union branch is a downstream name.  Update the generator to
mangle the union names in the appropriate places.

Signed-off-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
This commit is contained in:
Eric Blake 2015-05-14 06:50:58 -06:00 committed by Markus Armbruster
parent 83a02706bb
commit bb33729043
4 changed files with 10 additions and 7 deletions

View file

@ -193,7 +193,7 @@ const int %(name)s_qtypes[QTYPE_MAX] = {
def generate_union(expr, meta):
name = expr[meta]
name = c_name(expr[meta])
typeinfo = expr['data']
base = expr.get('base')