We want to eventually allow qapi defaults, by making:
 'data':{'*flag':'bool'}
 as shorthand for something like:
  'data':{'flag':{'type':'bool', 'optional':true}}
  so that the default can be specified:
   'data':{'flag':{'type':'bool', 'optional':true, 'default':true}}

This series does not quite get us there, but it DOES do a number
of other things.  It gets rid of the three uses of nested inline
structs, changes anonymous unions to use a specific 'alternate'
metatype rather than abusing 'union', changes the ambiguous 'type'
to the obvious 'struct', and fixes lots of other parser bugs found
while designing the testsuite.  The testsuite changes make the
bulk of this series, with a repeating pattern of writing tests
that expose weaknesses in the old parser, then beefing up the
generator to catch the problem during the initial parse rather
than choking with an obscure python message or even causing a C
compilation failure.

v7 was here:
https://lists.gnu.org/archive/html/qemu-devel/2015-04/msg04161.html

squash in a few patches found to be needed while working on the
next series

v6 was here:
https://lists.gnu.org/archive/html/qemu-devel/2015-04/msg00486.html

I split 30, and dropped R-b on 27 and 38 (v6:37). Everything else
was just minor changes, and described by this backport diff (cool
tool by the way - my first time using it!) - except that the \u
in the title of 38 led to a false negative in the tool claiming
it is a downstream-only patch.

v5 and earlier - read the mailing list archives

comparison to v7:

[----] : patches are identical
[####] : number of functional differences between upstream/downstream patch
[down] : patch is downstream-only
The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively
(False negative on 39, which is unchanged from v7, due to \u in subject)

001/40:[----] [--] 'qapi: Add copyright declaration on docs'
002/40:[----] [--] 'qapi: Document type-safety considerations'
003/40:[----] [--] 'qapi: Simplify builtin type handling'
004/40:[----] [--] 'qapi: Fix generation of 'size' builtin type'
005/40:[----] [--] 'qapi: Require ASCII in schema'
006/40:[----] [--] 'qapi: Add some enum tests'
007/40:[----] [--] 'qapi: Better error messages for bad enums'
008/40:[----] [--] 'qapi: Add some union tests'
009/40:[----] [--] 'qapi: Clean up test coverage of simple unions'
010/40:[----] [--] 'qapi: Forbid base without discriminator in unions'
011/40:[----] [--] 'qapi: Tighten checking of unions'
012/40:[----] [--] 'qapi: Prepare for catching more semantic parse errors'
013/40:[----] [--] 'qapi: Segregate anonymous unions into alternates in 
generator'
014/40:[----] [--] 'qapi: Rename anonymous union type in test'
015/40:[----] [--] 'qapi: Document new 'alternate' meta-type'
016/40:[----] [--] 'qapi: Use 'alternate' to replace anonymous union'
017/40:[----] [--] 'qapi: Add some expr tests'
018/40:[----] [--] 'qapi: Better error messages for bad expressions'
019/40:[----] [--] 'qapi: Add tests of redefined expressions'
020/40:[----] [--] 'qapi: Better error messages for duplicated expressions'
021/40:[----] [--] 'qapi: Allow true, false and null in schema json'
022/40:[0009] [FC] 'qapi: Unify type bypass and add tests'
023/40:[----] [--] 'qapi: Add some type check tests'
024/40:[----] [--] 'qapi: More rigourous checking of types'
025/40:[0002] [FC] 'qapi: Require valid names'
026/40:[----] [--] 'qapi: Whitelist commands that don't return dictionary'
027/40:[----] [--] 'qapi: More rigorous checking for type safety bypass'
028/40:[----] [--] 'qapi: Prefer 'struct' over 'type' in generator'
029/40:[----] [--] 'qapi: Document 'struct' metatype'
030/40:[----] [--] 'qapi: Use 'struct' instead of 'type' in schema'
031/40:[----] [--] 'qapi: Forbid 'type' in schema'
032/40:[----] [--] 'qapi: Merge UserDefTwo and UserDefNested in tests'
033/40:[----] [--] 'qapi: Drop tests for inline nested structs'
034/40:[----] [--] 'qapi: Drop inline nested struct in query-version'
035/40:[----] [--] 'qapi: Drop inline nested structs in query-pci'
036/40:[----] [--] 'qapi: Drop support for inline nested types'
037/40:[down] 'qapi: Drop dead visitor code related to nested structs'
038/40:[----] [--] 'qapi: Tweak doc references to QMP when QGA is also meant'
039/40:[down] 'qapi: Support (subset of) u escapes in strings'
040/40:[0008] [FC] 'qapi: Check for member name conflicts with a base class'

Eric Blake (39):
  qapi: Add copyright declaration on docs
  qapi: Document type-safety considerations
  qapi: Simplify builtin type handling
  qapi: Fix generation of 'size' builtin type
  qapi: Require ASCII in schema
  qapi: Add some enum tests
  qapi: Better error messages for bad enums
  qapi: Add some union tests
  qapi: Clean up test coverage of simple unions
  qapi: Forbid base without discriminator in unions
  qapi: Tighten checking of unions
  qapi: Prepare for catching more semantic parse errors
  qapi: Segregate anonymous unions into alternates in generator
  qapi: Rename anonymous union type in test
  qapi: Document new 'alternate' meta-type
  qapi: Use 'alternate' to replace anonymous union
  qapi: Add some expr tests
  qapi: Better error messages for bad expressions
  qapi: Add tests of redefined expressions
  qapi: Better error messages for duplicated expressions
  qapi: Unify type bypass and add tests
  qapi: Add some type check tests
  qapi: More rigourous checking of types
  qapi: Require valid names
  qapi: Whitelist commands that don't return dictionary
  qapi: More rigorous checking for type safety bypass
  qapi: Prefer 'struct' over 'type' in generator
  qapi: Document 'struct' metatype
  qapi: Use 'struct' instead of 'type' in schema
  qapi: Forbid 'type' in schema
  qapi: Merge UserDefTwo and UserDefNested in tests
  qapi: Drop tests for inline nested structs
  qapi: Drop inline nested struct in query-version
  qapi: Drop inline nested structs in query-pci
  qapi: Drop support for inline nested types
  qapi: Drop dead visitor code related to nested structs
  qapi: Tweak doc references to QMP when QGA is also meant
  qapi: Support (subset of) \u escapes in strings
  qapi: Check for member name conflicts with a base class

Fam Zheng (1):
  qapi: Allow true, false and null in schema json

 docs/qapi-code-gen.txt                             | 479 ++++++++++++++----
 docs/qmp/qmp-spec.txt                              | 115 ++++-
 hmp.c                                              |  28 +-
 hw/pci/pci.c                                       |  42 +-
 qapi-schema.json                                   | 270 ++++++-----
 qapi/block-core.json                               |  72 ++-
 qapi/block.json                                    |   2 +-
 qapi/common.json                                   |  30 +-
 qapi/trace.json                                    |   2 +-
 qga/qapi-schema.json                               |  36 +-
 qmp.c                                              |   9 +-
 scripts/qapi-commands.py                           |  17 +-
 scripts/qapi-event.py                              |   4 +-
 scripts/qapi-types.py                              |  77 ++-
 scripts/qapi-visit.py                              | 128 ++---
 scripts/qapi.py                                    | 536 +++++++++++++++++----
 tests/Makefile                                     |  38 +-
 tests/qapi-schema/alternate-array.err              |   1 +
 tests/qapi-schema/alternate-array.exit             |   1 +
 tests/qapi-schema/alternate-array.json             |   7 +
 tests/qapi-schema/alternate-array.out              |   0
 tests/qapi-schema/alternate-base.err               |   1 +
 tests/qapi-schema/alternate-base.exit              |   1 +
 tests/qapi-schema/alternate-base.json              |   6 +
 tests/qapi-schema/alternate-base.out               |   0
 tests/qapi-schema/alternate-clash.err              |   1 +
 tests/qapi-schema/alternate-clash.exit             |   1 +
 tests/qapi-schema/alternate-clash.json             |   3 +
 tests/qapi-schema/alternate-clash.out              |   0
 tests/qapi-schema/alternate-conflict-dict.err      |   1 +
 tests/qapi-schema/alternate-conflict-dict.exit     |   1 +
 tests/qapi-schema/alternate-conflict-dict.json     |   8 +
 tests/qapi-schema/alternate-conflict-dict.out      |   0
 tests/qapi-schema/alternate-conflict-string.err    |   1 +
 tests/qapi-schema/alternate-conflict-string.exit   |   1 +
 tests/qapi-schema/alternate-conflict-string.json   |   6 +
 tests/qapi-schema/alternate-conflict-string.out    |   0
 tests/qapi-schema/alternate-good.err               |   0
 tests/qapi-schema/alternate-good.exit              |   1 +
 tests/qapi-schema/alternate-good.json              |   9 +
 tests/qapi-schema/alternate-good.out               |   6 +
 tests/qapi-schema/alternate-nested.err             |   1 +
 tests/qapi-schema/alternate-nested.exit            |   1 +
 tests/qapi-schema/alternate-nested.json            |   5 +
 tests/qapi-schema/alternate-nested.out             |   0
 tests/qapi-schema/alternate-unknown.err            |   1 +
 tests/qapi-schema/alternate-unknown.exit           |   1 +
 tests/qapi-schema/alternate-unknown.json           |   3 +
 tests/qapi-schema/alternate-unknown.out            |   0
 tests/qapi-schema/bad-base.err                     |   1 +
 tests/qapi-schema/bad-base.exit                    |   1 +
 tests/qapi-schema/bad-base.json                    |   3 +
 tests/qapi-schema/bad-base.out                     |   0
 tests/qapi-schema/bad-data.err                     |   1 +
 tests/qapi-schema/bad-data.exit                    |   1 +
 tests/qapi-schema/bad-data.json                    |   2 +
 tests/qapi-schema/bad-data.out                     |   0
 tests/qapi-schema/bad-ident.err                    |   1 +
 tests/qapi-schema/bad-ident.exit                   |   1 +
 tests/qapi-schema/bad-ident.json                   |   2 +
 tests/qapi-schema/bad-ident.out                    |   0
 tests/qapi-schema/bad-type-bool.err                |   1 +
 tests/qapi-schema/bad-type-bool.exit               |   1 +
 tests/qapi-schema/bad-type-bool.json               |   2 +
 tests/qapi-schema/bad-type-bool.out                |   0
 tests/qapi-schema/bad-type-dict.err                |   1 +
 tests/qapi-schema/bad-type-dict.exit               |   1 +
 tests/qapi-schema/bad-type-dict.json               |   2 +
 tests/qapi-schema/bad-type-dict.out                |   0
 tests/qapi-schema/bad-type-int.err                 |   1 +
 tests/qapi-schema/bad-type-int.exit                |   1 +
 tests/qapi-schema/bad-type-int.json                |   3 +
 tests/qapi-schema/bad-type-int.out                 |   0
 tests/qapi-schema/command-int.err                  |   1 +
 tests/qapi-schema/command-int.exit                 |   1 +
 tests/qapi-schema/command-int.json                 |   3 +
 tests/qapi-schema/command-int.out                  |   0
 tests/qapi-schema/data-array-empty.err             |   1 +
 tests/qapi-schema/data-array-empty.exit            |   1 +
 tests/qapi-schema/data-array-empty.json            |   2 +
 tests/qapi-schema/data-array-empty.out             |   0
 tests/qapi-schema/data-array-unknown.err           |   1 +
 tests/qapi-schema/data-array-unknown.exit          |   1 +
 tests/qapi-schema/data-array-unknown.json          |   2 +
 tests/qapi-schema/data-array-unknown.out           |   0
 tests/qapi-schema/data-int.err                     |   1 +
 tests/qapi-schema/data-int.exit                    |   1 +
 tests/qapi-schema/data-int.json                    |   2 +
 tests/qapi-schema/data-int.out                     |   0
 tests/qapi-schema/data-member-array-bad.err        |   1 +
 tests/qapi-schema/data-member-array-bad.exit       |   1 +
 tests/qapi-schema/data-member-array-bad.json       |   2 +
 tests/qapi-schema/data-member-array-bad.out        |   0
 tests/qapi-schema/data-member-array.err            |   0
 tests/qapi-schema/data-member-array.exit           |   1 +
 tests/qapi-schema/data-member-array.json           |   4 +
 tests/qapi-schema/data-member-array.out            |   5 +
 tests/qapi-schema/data-member-unknown.err          |   1 +
 tests/qapi-schema/data-member-unknown.exit         |   1 +
 tests/qapi-schema/data-member-unknown.json         |   2 +
 tests/qapi-schema/data-member-unknown.out          |   0
 tests/qapi-schema/data-unknown.err                 |   1 +
 tests/qapi-schema/data-unknown.exit                |   1 +
 tests/qapi-schema/data-unknown.json                |   2 +
 tests/qapi-schema/data-unknown.out                 |   0
 tests/qapi-schema/double-data.err                  |   1 +
 tests/qapi-schema/double-data.exit                 |   1 +
 tests/qapi-schema/double-data.json                 |   2 +
 tests/qapi-schema/double-data.out                  |   0
 tests/qapi-schema/double-type.err                  |   1 +
 tests/qapi-schema/double-type.exit                 |   1 +
 tests/qapi-schema/double-type.json                 |   2 +
 tests/qapi-schema/double-type.out                  |   0
 tests/qapi-schema/enum-bad-name.err                |   1 +
 tests/qapi-schema/enum-bad-name.exit               |   1 +
 tests/qapi-schema/enum-bad-name.json               |   2 +
 tests/qapi-schema/enum-bad-name.out                |   0
 tests/qapi-schema/enum-clash-member.err            |   1 +
 tests/qapi-schema/enum-clash-member.exit           |   1 +
 tests/qapi-schema/enum-clash-member.json           |   2 +
 tests/qapi-schema/enum-clash-member.out            |   0
 tests/qapi-schema/enum-dict-member.err             |   1 +
 tests/qapi-schema/enum-dict-member.exit            |   1 +
 tests/qapi-schema/enum-dict-member.json            |   2 +
 tests/qapi-schema/enum-dict-member.out             |   0
 tests/qapi-schema/enum-empty.err                   |   0
 tests/qapi-schema/enum-empty.exit                  |   1 +
 tests/qapi-schema/enum-empty.json                  |   2 +
 tests/qapi-schema/enum-empty.out                   |   3 +
 tests/qapi-schema/enum-int-member.err              |   1 +
 tests/qapi-schema/enum-int-member.exit             |   1 +
 tests/qapi-schema/enum-int-member.json             |   3 +
 tests/qapi-schema/enum-int-member.out              |   0
 tests/qapi-schema/enum-max-member.err              |   1 +
 tests/qapi-schema/enum-max-member.exit             |   1 +
 tests/qapi-schema/enum-max-member.json             |   3 +
 tests/qapi-schema/enum-max-member.out              |   0
 tests/qapi-schema/enum-missing-data.err            |   1 +
 tests/qapi-schema/enum-missing-data.exit           |   1 +
 tests/qapi-schema/enum-missing-data.json           |   2 +
 tests/qapi-schema/enum-missing-data.out            |   0
 tests/qapi-schema/enum-union-clash.err             |   1 +
 tests/qapi-schema/enum-union-clash.exit            |   1 +
 tests/qapi-schema/enum-union-clash.json            |   4 +
 tests/qapi-schema/enum-union-clash.out             |   0
 tests/qapi-schema/enum-wrong-data.err              |   1 +
 tests/qapi-schema/enum-wrong-data.exit             |   1 +
 tests/qapi-schema/enum-wrong-data.json             |   2 +
 tests/qapi-schema/enum-wrong-data.out              |   0
 tests/qapi-schema/escape-outside-string.err        |   1 +
 tests/qapi-schema/escape-outside-string.exit       |   1 +
 tests/qapi-schema/escape-outside-string.json       |   3 +
 tests/qapi-schema/escape-outside-string.out        |   0
 tests/qapi-schema/escape-too-big.err               |   1 +
 tests/qapi-schema/escape-too-big.exit              |   1 +
 tests/qapi-schema/escape-too-big.json              |   3 +
 tests/qapi-schema/escape-too-big.out               |   0
 tests/qapi-schema/escape-too-short.err             |   1 +
 tests/qapi-schema/escape-too-short.exit            |   1 +
 tests/qapi-schema/escape-too-short.json            |   3 +
 tests/qapi-schema/escape-too-short.out             |   0
 tests/qapi-schema/event-case.err                   |   0
 tests/qapi-schema/event-case.exit                  |   1 +
 tests/qapi-schema/event-case.json                  |   3 +
 tests/qapi-schema/event-case.out                   |   3 +
 tests/qapi-schema/event-max.err                    |   1 +
 tests/qapi-schema/event-max.exit                   |   1 +
 tests/qapi-schema/event-max.json                   |   2 +
 tests/qapi-schema/event-max.out                    |   0
 tests/qapi-schema/event-nest-struct.err            |   2 +-
 tests/qapi-schema/flat-union-bad-base.err          |   1 +
 tests/qapi-schema/flat-union-bad-base.exit         |   1 +
 tests/qapi-schema/flat-union-bad-base.json         |  13 +
 tests/qapi-schema/flat-union-bad-base.out          |   0
 tests/qapi-schema/flat-union-bad-discriminator.err |   1 +
 .../qapi-schema/flat-union-bad-discriminator.exit  |   1 +
 .../qapi-schema/flat-union-bad-discriminator.json  |  15 +
 tests/qapi-schema/flat-union-bad-discriminator.out |   0
 tests/qapi-schema/flat-union-base-star.err         |   1 +
 tests/qapi-schema/flat-union-base-star.exit        |   1 +
 tests/qapi-schema/flat-union-base-star.json        |  12 +
 tests/qapi-schema/flat-union-base-star.out         |   0
 tests/qapi-schema/flat-union-base-union.err        |   1 +
 tests/qapi-schema/flat-union-base-union.exit       |   1 +
 tests/qapi-schema/flat-union-base-union.json       |  15 +
 tests/qapi-schema/flat-union-base-union.out        |   0
 tests/qapi-schema/flat-union-branch-clash.err      |   1 +
 tests/qapi-schema/flat-union-branch-clash.exit     |   1 +
 tests/qapi-schema/flat-union-branch-clash.json     |  14 +
 tests/qapi-schema/flat-union-branch-clash.out      |   0
 tests/qapi-schema/flat-union-inline.err            |   1 +
 tests/qapi-schema/flat-union-inline.exit           |   1 +
 tests/qapi-schema/flat-union-inline.json           |  11 +
 tests/qapi-schema/flat-union-inline.out            |   0
 tests/qapi-schema/flat-union-int-branch.err        |   1 +
 tests/qapi-schema/flat-union-int-branch.exit       |   1 +
 tests/qapi-schema/flat-union-int-branch.json       |  12 +
 tests/qapi-schema/flat-union-int-branch.out        |   0
 .../qapi-schema/flat-union-invalid-branch-key.json |   6 +-
 .../flat-union-invalid-discriminator.err           |   2 +-
 .../flat-union-invalid-discriminator.json          |   6 +-
 tests/qapi-schema/flat-union-no-base.err           |   2 +-
 tests/qapi-schema/flat-union-no-base.json          |  12 +-
 .../flat-union-optional-discriminator.err          |   1 +
 .../flat-union-optional-discriminator.exit         |   1 +
 .../flat-union-optional-discriminator.json         |  10 +
 .../flat-union-optional-discriminator.out          |   0
 tests/qapi-schema/flat-union-reverse-define.json   |   6 +-
 tests/qapi-schema/flat-union-reverse-define.out    |  12 +-
 .../flat-union-string-discriminator.json           |   6 +-
 tests/qapi-schema/ident-with-escape.err            |   0
 tests/qapi-schema/ident-with-escape.exit           |   1 +
 tests/qapi-schema/ident-with-escape.json           |   4 +
 tests/qapi-schema/ident-with-escape.out            |   3 +
 tests/qapi-schema/indented-expr.json               |   4 +-
 tests/qapi-schema/indented-expr.out                |   2 +-
 tests/qapi-schema/missing-type.err                 |   1 +
 tests/qapi-schema/missing-type.exit                |   1 +
 tests/qapi-schema/missing-type.json                |   2 +
 tests/qapi-schema/missing-type.out                 |   0
 tests/qapi-schema/nested-struct-data.err           |   1 +
 tests/qapi-schema/nested-struct-data.exit          |   1 +
 tests/qapi-schema/nested-struct-data.json          |   4 +
 tests/qapi-schema/nested-struct-data.out           |   0
 tests/qapi-schema/nested-struct-returns.err        |   1 +
 tests/qapi-schema/nested-struct-returns.exit       |   1 +
 tests/qapi-schema/nested-struct-returns.json       |   3 +
 tests/qapi-schema/nested-struct-returns.out        |   0
 tests/qapi-schema/qapi-schema-test.json            |  46 +-
 tests/qapi-schema/qapi-schema-test.out             |  54 +--
 tests/qapi-schema/redefined-builtin.err            |   1 +
 tests/qapi-schema/redefined-builtin.exit           |   1 +
 tests/qapi-schema/redefined-builtin.json           |   2 +
 tests/qapi-schema/redefined-builtin.out            |   0
 tests/qapi-schema/redefined-command.err            |   1 +
 tests/qapi-schema/redefined-command.exit           |   1 +
 tests/qapi-schema/redefined-command.json           |   3 +
 tests/qapi-schema/redefined-command.out            |   0
 tests/qapi-schema/redefined-event.err              |   1 +
 tests/qapi-schema/redefined-event.exit             |   1 +
 tests/qapi-schema/redefined-event.json             |   3 +
 tests/qapi-schema/redefined-event.out              |   0
 tests/qapi-schema/redefined-type.err               |   1 +
 tests/qapi-schema/redefined-type.exit              |   1 +
 tests/qapi-schema/redefined-type.json              |   3 +
 tests/qapi-schema/redefined-type.out               |   0
 tests/qapi-schema/returns-alternate.err            |   1 +
 tests/qapi-schema/returns-alternate.exit           |   1 +
 tests/qapi-schema/returns-alternate.json           |   3 +
 tests/qapi-schema/returns-alternate.out            |   0
 tests/qapi-schema/returns-array-bad.err            |   1 +
 tests/qapi-schema/returns-array-bad.exit           |   1 +
 tests/qapi-schema/returns-array-bad.json           |   2 +
 tests/qapi-schema/returns-array-bad.out            |   0
 tests/qapi-schema/returns-int.err                  |   0
 tests/qapi-schema/returns-int.exit                 |   1 +
 tests/qapi-schema/returns-int.json                 |   3 +
 tests/qapi-schema/returns-int.out                  |   3 +
 tests/qapi-schema/returns-unknown.err              |   1 +
 tests/qapi-schema/returns-unknown.exit             |   1 +
 tests/qapi-schema/returns-unknown.json             |   2 +
 tests/qapi-schema/returns-unknown.out              |   0
 tests/qapi-schema/returns-whitelist.err            |   1 +
 tests/qapi-schema/returns-whitelist.exit           |   1 +
 tests/qapi-schema/returns-whitelist.json           |  11 +
 tests/qapi-schema/returns-whitelist.out            |   0
 tests/qapi-schema/struct-base-clash-deep.err       |   1 +
 tests/qapi-schema/struct-base-clash-deep.exit      |   1 +
 tests/qapi-schema/struct-base-clash-deep.json      |   9 +
 tests/qapi-schema/struct-base-clash-deep.out       |   0
 tests/qapi-schema/struct-base-clash.err            |   1 +
 tests/qapi-schema/struct-base-clash.exit           |   1 +
 tests/qapi-schema/struct-base-clash.json           |   6 +
 tests/qapi-schema/struct-base-clash.out            |   0
 tests/qapi-schema/type-bypass-bad-gen.err          |   1 +
 tests/qapi-schema/type-bypass-bad-gen.exit         |   1 +
 tests/qapi-schema/type-bypass-bad-gen.json         |   2 +
 tests/qapi-schema/type-bypass-bad-gen.out          |   0
 tests/qapi-schema/type-bypass-no-gen.err           |   1 +
 tests/qapi-schema/type-bypass-no-gen.exit          |   1 +
 tests/qapi-schema/type-bypass-no-gen.json          |   2 +
 tests/qapi-schema/type-bypass-no-gen.out           |   0
 tests/qapi-schema/type-bypass.err                  |   0
 tests/qapi-schema/type-bypass.exit                 |   1 +
 tests/qapi-schema/type-bypass.json                 |   2 +
 tests/qapi-schema/type-bypass.out                  |   3 +
 tests/qapi-schema/unicode-str.err                  |   1 +
 tests/qapi-schema/unicode-str.exit                 |   1 +
 tests/qapi-schema/unicode-str.json                 |   2 +
 tests/qapi-schema/unicode-str.out                  |   0
 tests/qapi-schema/union-bad-branch.err             |   1 +
 tests/qapi-schema/union-bad-branch.exit            |   1 +
 tests/qapi-schema/union-bad-branch.json            |   8 +
 tests/qapi-schema/union-bad-branch.out             |   0
 tests/qapi-schema/union-base-no-discriminator.err  |   1 +
 tests/qapi-schema/union-base-no-discriminator.exit |   1 +
 tests/qapi-schema/union-base-no-discriminator.json |  14 +
 tests/qapi-schema/union-base-no-discriminator.out  |   0
 tests/qapi-schema/union-invalid-base.err           |   2 +-
 tests/qapi-schema/union-invalid-base.json          |   8 +-
 tests/qapi-schema/union-max.err                    |   1 +
 tests/qapi-schema/union-max.exit                   |   1 +
 tests/qapi-schema/union-max.json                   |   3 +
 tests/qapi-schema/union-max.out                    |   0
 tests/qapi-schema/union-optional-branch.err        |   1 +
 tests/qapi-schema/union-optional-branch.exit       |   1 +
 tests/qapi-schema/union-optional-branch.json       |   2 +
 tests/qapi-schema/union-optional-branch.out        |   0
 tests/qapi-schema/union-unknown.err                |   1 +
 tests/qapi-schema/union-unknown.exit               |   1 +
 tests/qapi-schema/union-unknown.json               |   3 +
 tests/qapi-schema/union-unknown.out                |   0
 tests/qapi-schema/unknown-escape.err               |   1 +
 tests/qapi-schema/unknown-escape.exit              |   1 +
 tests/qapi-schema/unknown-escape.json              |   3 +
 tests/qapi-schema/unknown-escape.out               |   0
 tests/qapi-schema/unknown-expr-key.err             |   1 +
 tests/qapi-schema/unknown-expr-key.exit            |   1 +
 tests/qapi-schema/unknown-expr-key.json            |   2 +
 tests/qapi-schema/unknown-expr-key.out             |   0
 tests/test-qmp-commands.c                          |  37 +-
 tests/test-qmp-input-strict.c                      |  98 ++--
 tests/test-qmp-input-visitor.c                     | 117 ++---
 tests/test-qmp-output-visitor.c                    | 152 +++---
 tests/test-visitor-serialization.c                 |  87 ++--
 325 files changed, 2108 insertions(+), 926 deletions(-)
 create mode 100644 tests/qapi-schema/alternate-array.err
 create mode 100644 tests/qapi-schema/alternate-array.exit
 create mode 100644 tests/qapi-schema/alternate-array.json
 create mode 100644 tests/qapi-schema/alternate-array.out
 create mode 100644 tests/qapi-schema/alternate-base.err
 create mode 100644 tests/qapi-schema/alternate-base.exit
 create mode 100644 tests/qapi-schema/alternate-base.json
 create mode 100644 tests/qapi-schema/alternate-base.out
 create mode 100644 tests/qapi-schema/alternate-clash.err
 create mode 100644 tests/qapi-schema/alternate-clash.exit
 create mode 100644 tests/qapi-schema/alternate-clash.json
 create mode 100644 tests/qapi-schema/alternate-clash.out
 create mode 100644 tests/qapi-schema/alternate-conflict-dict.err
 create mode 100644 tests/qapi-schema/alternate-conflict-dict.exit
 create mode 100644 tests/qapi-schema/alternate-conflict-dict.json
 create mode 100644 tests/qapi-schema/alternate-conflict-dict.out
 create mode 100644 tests/qapi-schema/alternate-conflict-string.err
 create mode 100644 tests/qapi-schema/alternate-conflict-string.exit
 create mode 100644 tests/qapi-schema/alternate-conflict-string.json
 create mode 100644 tests/qapi-schema/alternate-conflict-string.out
 create mode 100644 tests/qapi-schema/alternate-good.err
 create mode 100644 tests/qapi-schema/alternate-good.exit
 create mode 100644 tests/qapi-schema/alternate-good.json
 create mode 100644 tests/qapi-schema/alternate-good.out
 create mode 100644 tests/qapi-schema/alternate-nested.err
 create mode 100644 tests/qapi-schema/alternate-nested.exit
 create mode 100644 tests/qapi-schema/alternate-nested.json
 create mode 100644 tests/qapi-schema/alternate-nested.out
 create mode 100644 tests/qapi-schema/alternate-unknown.err
 create mode 100644 tests/qapi-schema/alternate-unknown.exit
 create mode 100644 tests/qapi-schema/alternate-unknown.json
 create mode 100644 tests/qapi-schema/alternate-unknown.out
 create mode 100644 tests/qapi-schema/bad-base.err
 create mode 100644 tests/qapi-schema/bad-base.exit
 create mode 100644 tests/qapi-schema/bad-base.json
 create mode 100644 tests/qapi-schema/bad-base.out
 create mode 100644 tests/qapi-schema/bad-data.err
 create mode 100644 tests/qapi-schema/bad-data.exit
 create mode 100644 tests/qapi-schema/bad-data.json
 create mode 100644 tests/qapi-schema/bad-data.out
 create mode 100644 tests/qapi-schema/bad-ident.err
 create mode 100644 tests/qapi-schema/bad-ident.exit
 create mode 100644 tests/qapi-schema/bad-ident.json
 create mode 100644 tests/qapi-schema/bad-ident.out
 create mode 100644 tests/qapi-schema/bad-type-bool.err
 create mode 100644 tests/qapi-schema/bad-type-bool.exit
 create mode 100644 tests/qapi-schema/bad-type-bool.json
 create mode 100644 tests/qapi-schema/bad-type-bool.out
 create mode 100644 tests/qapi-schema/bad-type-dict.err
 create mode 100644 tests/qapi-schema/bad-type-dict.exit
 create mode 100644 tests/qapi-schema/bad-type-dict.json
 create mode 100644 tests/qapi-schema/bad-type-dict.out
 create mode 100644 tests/qapi-schema/bad-type-int.err
 create mode 100644 tests/qapi-schema/bad-type-int.exit
 create mode 100644 tests/qapi-schema/bad-type-int.json
 create mode 100644 tests/qapi-schema/bad-type-int.out
 create mode 100644 tests/qapi-schema/command-int.err
 create mode 100644 tests/qapi-schema/command-int.exit
 create mode 100644 tests/qapi-schema/command-int.json
 create mode 100644 tests/qapi-schema/command-int.out
 create mode 100644 tests/qapi-schema/data-array-empty.err
 create mode 100644 tests/qapi-schema/data-array-empty.exit
 create mode 100644 tests/qapi-schema/data-array-empty.json
 create mode 100644 tests/qapi-schema/data-array-empty.out
 create mode 100644 tests/qapi-schema/data-array-unknown.err
 create mode 100644 tests/qapi-schema/data-array-unknown.exit
 create mode 100644 tests/qapi-schema/data-array-unknown.json
 create mode 100644 tests/qapi-schema/data-array-unknown.out
 create mode 100644 tests/qapi-schema/data-int.err
 create mode 100644 tests/qapi-schema/data-int.exit
 create mode 100644 tests/qapi-schema/data-int.json
 create mode 100644 tests/qapi-schema/data-int.out
 create mode 100644 tests/qapi-schema/data-member-array-bad.err
 create mode 100644 tests/qapi-schema/data-member-array-bad.exit
 create mode 100644 tests/qapi-schema/data-member-array-bad.json
 create mode 100644 tests/qapi-schema/data-member-array-bad.out
 create mode 100644 tests/qapi-schema/data-member-array.err
 create mode 100644 tests/qapi-schema/data-member-array.exit
 create mode 100644 tests/qapi-schema/data-member-array.json
 create mode 100644 tests/qapi-schema/data-member-array.out
 create mode 100644 tests/qapi-schema/data-member-unknown.err
 create mode 100644 tests/qapi-schema/data-member-unknown.exit
 create mode 100644 tests/qapi-schema/data-member-unknown.json
 create mode 100644 tests/qapi-schema/data-member-unknown.out
 create mode 100644 tests/qapi-schema/data-unknown.err
 create mode 100644 tests/qapi-schema/data-unknown.exit
 create mode 100644 tests/qapi-schema/data-unknown.json
 create mode 100644 tests/qapi-schema/data-unknown.out
 create mode 100644 tests/qapi-schema/double-data.err
 create mode 100644 tests/qapi-schema/double-data.exit
 create mode 100644 tests/qapi-schema/double-data.json
 create mode 100644 tests/qapi-schema/double-data.out
 create mode 100644 tests/qapi-schema/double-type.err
 create mode 100644 tests/qapi-schema/double-type.exit
 create mode 100644 tests/qapi-schema/double-type.json
 create mode 100644 tests/qapi-schema/double-type.out
 create mode 100644 tests/qapi-schema/enum-bad-name.err
 create mode 100644 tests/qapi-schema/enum-bad-name.exit
 create mode 100644 tests/qapi-schema/enum-bad-name.json
 create mode 100644 tests/qapi-schema/enum-bad-name.out
 create mode 100644 tests/qapi-schema/enum-clash-member.err
 create mode 100644 tests/qapi-schema/enum-clash-member.exit
 create mode 100644 tests/qapi-schema/enum-clash-member.json
 create mode 100644 tests/qapi-schema/enum-clash-member.out
 create mode 100644 tests/qapi-schema/enum-dict-member.err
 create mode 100644 tests/qapi-schema/enum-dict-member.exit
 create mode 100644 tests/qapi-schema/enum-dict-member.json
 create mode 100644 tests/qapi-schema/enum-dict-member.out
 create mode 100644 tests/qapi-schema/enum-empty.err
 create mode 100644 tests/qapi-schema/enum-empty.exit
 create mode 100644 tests/qapi-schema/enum-empty.json
 create mode 100644 tests/qapi-schema/enum-empty.out
 create mode 100644 tests/qapi-schema/enum-int-member.err
 create mode 100644 tests/qapi-schema/enum-int-member.exit
 create mode 100644 tests/qapi-schema/enum-int-member.json
 create mode 100644 tests/qapi-schema/enum-int-member.out
 create mode 100644 tests/qapi-schema/enum-max-member.err
 create mode 100644 tests/qapi-schema/enum-max-member.exit
 create mode 100644 tests/qapi-schema/enum-max-member.json
 create mode 100644 tests/qapi-schema/enum-max-member.out
 create mode 100644 tests/qapi-schema/enum-missing-data.err
 create mode 100644 tests/qapi-schema/enum-missing-data.exit
 create mode 100644 tests/qapi-schema/enum-missing-data.json
 create mode 100644 tests/qapi-schema/enum-missing-data.out
 create mode 100644 tests/qapi-schema/enum-union-clash.err
 create mode 100644 tests/qapi-schema/enum-union-clash.exit
 create mode 100644 tests/qapi-schema/enum-union-clash.json
 create mode 100644 tests/qapi-schema/enum-union-clash.out
 create mode 100644 tests/qapi-schema/enum-wrong-data.err
 create mode 100644 tests/qapi-schema/enum-wrong-data.exit
 create mode 100644 tests/qapi-schema/enum-wrong-data.json
 create mode 100644 tests/qapi-schema/enum-wrong-data.out
 create mode 100644 tests/qapi-schema/escape-outside-string.err
 create mode 100644 tests/qapi-schema/escape-outside-string.exit
 create mode 100644 tests/qapi-schema/escape-outside-string.json
 create mode 100644 tests/qapi-schema/escape-outside-string.out
 create mode 100644 tests/qapi-schema/escape-too-big.err
 create mode 100644 tests/qapi-schema/escape-too-big.exit
 create mode 100644 tests/qapi-schema/escape-too-big.json
 create mode 100644 tests/qapi-schema/escape-too-big.out
 create mode 100644 tests/qapi-schema/escape-too-short.err
 create mode 100644 tests/qapi-schema/escape-too-short.exit
 create mode 100644 tests/qapi-schema/escape-too-short.json
 create mode 100644 tests/qapi-schema/escape-too-short.out
 create mode 100644 tests/qapi-schema/event-case.err
 create mode 100644 tests/qapi-schema/event-case.exit
 create mode 100644 tests/qapi-schema/event-case.json
 create mode 100644 tests/qapi-schema/event-case.out
 create mode 100644 tests/qapi-schema/event-max.err
 create mode 100644 tests/qapi-schema/event-max.exit
 create mode 100644 tests/qapi-schema/event-max.json
 create mode 100644 tests/qapi-schema/event-max.out
 create mode 100644 tests/qapi-schema/flat-union-bad-base.err
 create mode 100644 tests/qapi-schema/flat-union-bad-base.exit
 create mode 100644 tests/qapi-schema/flat-union-bad-base.json
 create mode 100644 tests/qapi-schema/flat-union-bad-base.out
 create mode 100644 tests/qapi-schema/flat-union-bad-discriminator.err
 create mode 100644 tests/qapi-schema/flat-union-bad-discriminator.exit
 create mode 100644 tests/qapi-schema/flat-union-bad-discriminator.json
 create mode 100644 tests/qapi-schema/flat-union-bad-discriminator.out
 create mode 100644 tests/qapi-schema/flat-union-base-star.err
 create mode 100644 tests/qapi-schema/flat-union-base-star.exit
 create mode 100644 tests/qapi-schema/flat-union-base-star.json
 create mode 100644 tests/qapi-schema/flat-union-base-star.out
 create mode 100644 tests/qapi-schema/flat-union-base-union.err
 create mode 100644 tests/qapi-schema/flat-union-base-union.exit
 create mode 100644 tests/qapi-schema/flat-union-base-union.json
 create mode 100644 tests/qapi-schema/flat-union-base-union.out
 create mode 100644 tests/qapi-schema/flat-union-branch-clash.err
 create mode 100644 tests/qapi-schema/flat-union-branch-clash.exit
 create mode 100644 tests/qapi-schema/flat-union-branch-clash.json
 create mode 100644 tests/qapi-schema/flat-union-branch-clash.out
 create mode 100644 tests/qapi-schema/flat-union-inline.err
 create mode 100644 tests/qapi-schema/flat-union-inline.exit
 create mode 100644 tests/qapi-schema/flat-union-inline.json
 create mode 100644 tests/qapi-schema/flat-union-inline.out
 create mode 100644 tests/qapi-schema/flat-union-int-branch.err
 create mode 100644 tests/qapi-schema/flat-union-int-branch.exit
 create mode 100644 tests/qapi-schema/flat-union-int-branch.json
 create mode 100644 tests/qapi-schema/flat-union-int-branch.out
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator.err
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator.exit
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator.json
 create mode 100644 tests/qapi-schema/flat-union-optional-discriminator.out
 create mode 100644 tests/qapi-schema/ident-with-escape.err
 create mode 100644 tests/qapi-schema/ident-with-escape.exit
 create mode 100644 tests/qapi-schema/ident-with-escape.json
 create mode 100644 tests/qapi-schema/ident-with-escape.out
 create mode 100644 tests/qapi-schema/missing-type.err
 create mode 100644 tests/qapi-schema/missing-type.exit
 create mode 100644 tests/qapi-schema/missing-type.json
 create mode 100644 tests/qapi-schema/missing-type.out
 create mode 100644 tests/qapi-schema/nested-struct-data.err
 create mode 100644 tests/qapi-schema/nested-struct-data.exit
 create mode 100644 tests/qapi-schema/nested-struct-data.json
 create mode 100644 tests/qapi-schema/nested-struct-data.out
 create mode 100644 tests/qapi-schema/nested-struct-returns.err
 create mode 100644 tests/qapi-schema/nested-struct-returns.exit
 create mode 100644 tests/qapi-schema/nested-struct-returns.json
 create mode 100644 tests/qapi-schema/nested-struct-returns.out
 create mode 100644 tests/qapi-schema/redefined-builtin.err
 create mode 100644 tests/qapi-schema/redefined-builtin.exit
 create mode 100644 tests/qapi-schema/redefined-builtin.json
 create mode 100644 tests/qapi-schema/redefined-builtin.out
 create mode 100644 tests/qapi-schema/redefined-command.err
 create mode 100644 tests/qapi-schema/redefined-command.exit
 create mode 100644 tests/qapi-schema/redefined-command.json
 create mode 100644 tests/qapi-schema/redefined-command.out
 create mode 100644 tests/qapi-schema/redefined-event.err
 create mode 100644 tests/qapi-schema/redefined-event.exit
 create mode 100644 tests/qapi-schema/redefined-event.json
 create mode 100644 tests/qapi-schema/redefined-event.out
 create mode 100644 tests/qapi-schema/redefined-type.err
 create mode 100644 tests/qapi-schema/redefined-type.exit
 create mode 100644 tests/qapi-schema/redefined-type.json
 create mode 100644 tests/qapi-schema/redefined-type.out
 create mode 100644 tests/qapi-schema/returns-alternate.err
 create mode 100644 tests/qapi-schema/returns-alternate.exit
 create mode 100644 tests/qapi-schema/returns-alternate.json
 create mode 100644 tests/qapi-schema/returns-alternate.out
 create mode 100644 tests/qapi-schema/returns-array-bad.err
 create mode 100644 tests/qapi-schema/returns-array-bad.exit
 create mode 100644 tests/qapi-schema/returns-array-bad.json
 create mode 100644 tests/qapi-schema/returns-array-bad.out
 create mode 100644 tests/qapi-schema/returns-int.err
 create mode 100644 tests/qapi-schema/returns-int.exit
 create mode 100644 tests/qapi-schema/returns-int.json
 create mode 100644 tests/qapi-schema/returns-int.out
 create mode 100644 tests/qapi-schema/returns-unknown.err
 create mode 100644 tests/qapi-schema/returns-unknown.exit
 create mode 100644 tests/qapi-schema/returns-unknown.json
 create mode 100644 tests/qapi-schema/returns-unknown.out
 create mode 100644 tests/qapi-schema/returns-whitelist.err
 create mode 100644 tests/qapi-schema/returns-whitelist.exit
 create mode 100644 tests/qapi-schema/returns-whitelist.json
 create mode 100644 tests/qapi-schema/returns-whitelist.out
 create mode 100644 tests/qapi-schema/struct-base-clash-deep.err
 create mode 100644 tests/qapi-schema/struct-base-clash-deep.exit
 create mode 100644 tests/qapi-schema/struct-base-clash-deep.json
 create mode 100644 tests/qapi-schema/struct-base-clash-deep.out
 create mode 100644 tests/qapi-schema/struct-base-clash.err
 create mode 100644 tests/qapi-schema/struct-base-clash.exit
 create mode 100644 tests/qapi-schema/struct-base-clash.json
 create mode 100644 tests/qapi-schema/struct-base-clash.out
 create mode 100644 tests/qapi-schema/type-bypass-bad-gen.err
 create mode 100644 tests/qapi-schema/type-bypass-bad-gen.exit
 create mode 100644 tests/qapi-schema/type-bypass-bad-gen.json
 create mode 100644 tests/qapi-schema/type-bypass-bad-gen.out
 create mode 100644 tests/qapi-schema/type-bypass-no-gen.err
 create mode 100644 tests/qapi-schema/type-bypass-no-gen.exit
 create mode 100644 tests/qapi-schema/type-bypass-no-gen.json
 create mode 100644 tests/qapi-schema/type-bypass-no-gen.out
 create mode 100644 tests/qapi-schema/type-bypass.err
 create mode 100644 tests/qapi-schema/type-bypass.exit
 create mode 100644 tests/qapi-schema/type-bypass.json
 create mode 100644 tests/qapi-schema/type-bypass.out
 create mode 100644 tests/qapi-schema/unicode-str.err
 create mode 100644 tests/qapi-schema/unicode-str.exit
 create mode 100644 tests/qapi-schema/unicode-str.json
 create mode 100644 tests/qapi-schema/unicode-str.out
 create mode 100644 tests/qapi-schema/union-bad-branch.err
 create mode 100644 tests/qapi-schema/union-bad-branch.exit
 create mode 100644 tests/qapi-schema/union-bad-branch.json
 create mode 100644 tests/qapi-schema/union-bad-branch.out
 create mode 100644 tests/qapi-schema/union-base-no-discriminator.err
 create mode 100644 tests/qapi-schema/union-base-no-discriminator.exit
 create mode 100644 tests/qapi-schema/union-base-no-discriminator.json
 create mode 100644 tests/qapi-schema/union-base-no-discriminator.out
 create mode 100644 tests/qapi-schema/union-max.err
 create mode 100644 tests/qapi-schema/union-max.exit
 create mode 100644 tests/qapi-schema/union-max.json
 create mode 100644 tests/qapi-schema/union-max.out
 create mode 100644 tests/qapi-schema/union-optional-branch.err
 create mode 100644 tests/qapi-schema/union-optional-branch.exit
 create mode 100644 tests/qapi-schema/union-optional-branch.json
 create mode 100644 tests/qapi-schema/union-optional-branch.out
 create mode 100644 tests/qapi-schema/union-unknown.err
 create mode 100644 tests/qapi-schema/union-unknown.exit
 create mode 100644 tests/qapi-schema/union-unknown.json
 create mode 100644 tests/qapi-schema/union-unknown.out
 create mode 100644 tests/qapi-schema/unknown-escape.err
 create mode 100644 tests/qapi-schema/unknown-escape.exit
 create mode 100644 tests/qapi-schema/unknown-escape.json
 create mode 100644 tests/qapi-schema/unknown-escape.out
 create mode 100644 tests/qapi-schema/unknown-expr-key.err
 create mode 100644 tests/qapi-schema/unknown-expr-key.exit
 create mode 100644 tests/qapi-schema/unknown-expr-key.json
 create mode 100644 tests/qapi-schema/unknown-expr-key.out

-- 
2.1.0


Reply via email to