aboutsummaryrefslogtreecommitdiff
path: root/scripts/modules
diff options
context:
space:
mode:
authorJohn Snow <jsnow@redhat.com>2021-02-15 21:18:04 -0500
committerMarkus Armbruster <armbru@redhat.com>2021-02-18 19:45:20 +0100
commit82b52f6b84585f1ea2a6ceb9fc0f264e3b13ed48 (patch)
tree04f8ac136cb5df583b5f37b035e4aa77b0418e7c /scripts/modules
parentcf5db2142b674ebab8e0799fd07e3884cfb00fc5 (diff)
downloadqemu-82b52f6b84585f1ea2a6ceb9fc0f264e3b13ed48.zip
qemu-82b52f6b84585f1ea2a6ceb9fc0f264e3b13ed48.tar.gz
qemu-82b52f6b84585f1ea2a6ceb9fc0f264e3b13ed48.tar.bz2
qapi/introspect.py: add type hint annotations
NB: The type aliases (SchemaInfo et al) declare intent for some of the "dictly-typed" objects we pass around in introspect.py. They do not enforce the shape of those objects, and cannot, until Python 3.7 or later. (And even then, it may not be "worth it".) Annotations are also added to the QAPISchemaEntity __init__ method in schema.py to allow mypy to statically prove the type of typ.name, needed to prove the return type of QAPISchemaGenIntrospectVisitor._use_type(). Signed-off-by: John Snow <jsnow@redhat.com> Message-Id: <20210216021809.134886-15-jsnow@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> [Note on QAPISchemaEntity.__init__() squashed into commit message, Comment wrapped to conform to PEP 8] Signed-off-by: Markus Armbruster <armbru@redhat.com>
Diffstat (limited to 'scripts/modules')
0 files changed, 0 insertions, 0 deletions