aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/qapi/source.py
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2024-03-15 20:57:56 +0100
committerMarkus Armbruster <armbru@redhat.com>2024-05-06 12:38:27 +0200
commit8152bc7de6d4377d5104078115aa61986b436f44 (patch)
tree4f7db5d0e561c028a3af388b5f1ac607122004e2 /scripts/qapi/source.py
parentqapi: Rename QAPISchemaAlternateType.variants to .alternatives (diff)
downloadqemu-8152bc7de6d4377d5104078115aa61986b436f44.tar.xz
qemu-8152bc7de6d4377d5104078115aa61986b436f44.zip
qapi: Move conditional code from QAPISchemaVariants to its subtypes
QAPISchemaVariants.check()'s code is almost entirely conditional on union vs. alternate type. Move the conditional code to QAPISchemaBranches.check() and QAPISchemaAlternatives.check(), where the conditions are always satisfied. Attribute QAPISchemaVariants.tag_name is now only used by QAPISchemaBranches. Move it there. Refactor the three types' .__init__() to make them a bit simpler. Signed-off-by: Markus Armbruster <armbru@redhat.com>
Diffstat (limited to 'scripts/qapi/source.py')
0 files changed, 0 insertions, 0 deletions