diff options
| author | Markus Armbruster <armbru@redhat.com> | 2022-11-04 17:07:11 +0100 |
|---|---|---|
| committer | Markus Armbruster <armbru@redhat.com> | 2022-12-14 20:05:07 +0100 |
| commit | 91eab32a3fcc14d3243cbd1c97f022796d4063e6 (patch) | |
| tree | 633c10253ce9680e320a418dc13b3cd6b159a840 /scripts/qapi/schema.py | |
| parent | 41462e41063c019df13e52735eae7197205a4b67 (diff) | |
| download | focaccia-qemu-91eab32a3fcc14d3243cbd1c97f022796d4063e6.tar.gz focaccia-qemu-91eab32a3fcc14d3243cbd1c97f022796d4063e6.zip | |
qapi qga: Elide redundant has_FOO in generated C
The has_FOO for pointer-valued FOO are redundant, except for arrays. They are also a nuisance to work with. Recent commit "qapi: Start to elide redundant has_FOO in generated C" provided the means to elide them step by step. This is the step for qga/qapi-schema.json. Said commit explains the transformation in more detail. The invariant violations mentioned there do not occur here. Cc: Michael Roth <michael.roth@amd.com> Cc: Konstantin Kostiuk <kkostiuk@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20221104160712.3005652-30-armbru@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Diffstat (limited to 'scripts/qapi/schema.py')
| -rw-r--r-- | scripts/qapi/schema.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/scripts/qapi/schema.py b/scripts/qapi/schema.py index b2df148e01..4594c69d0b 100644 --- a/scripts/qapi/schema.py +++ b/scripts/qapi/schema.py @@ -758,8 +758,7 @@ class QAPISchemaObjectTypeMember(QAPISchemaMember): def need_has(self): assert self.type # Temporary hack to support dropping the has_FOO in reviewable chunks - opt_out = [ - 'qga/qapi-schema.json'] + opt_out = [] if self.info and any(self.info.fname.endswith(mod) for mod in opt_out): return self.optional |