qapi/introspect: Use @dataclass to simplify
authorMarkus Armbruster <armbru@redhat.com>
Thu, 27 Feb 2025 08:07:57 +0000 (09:07 +0100)
committerMarkus Armbruster <armbru@redhat.com>
Thu, 6 Mar 2025 09:09:25 +0000 (10:09 +0100)
commite6985cc4407ddb14a27a282efc0b4c8d34534317
treea96c6c7b171c4504156516fc31901f3f6bb9bfc9
parent5fbc8126acaf07a0294f8f94f4c244c3c5b62d5d
qapi/introspect: Use @dataclass to simplify

A TODO comment in class Annotated reminds us to simplify it once we
can use @dataclass, new in Python 3.7.  We have that now, so do it.

There's a similar comment in scripts/qapi/source.py, but I can't
figure out how to use @dataclass there.  Left for another day.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20250227080757.3978333-4-armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
scripts/qapi/introspect.py