aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2018-02-11 10:35:50 +0100
committerEric Blake <eblake@redhat.com>2018-03-02 13:14:09 -0600
commit71a7510baf8a5745eb844ab289f007ff8bbbee41 (patch)
tree3bd5ebd011501cd1dbd171a3e3663f35f52751f6
parentaf97502ce9c648ae5c746b9e562d6e4586f02eee (diff)
qapi/common: Eliminate QAPISchema.exprs
Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20180211093607.27351-13-armbru@redhat.com> Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Eric Blake <eblake@redhat.com>
-rw-r--r--scripts/qapi/common.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/qapi/common.py b/scripts/qapi/common.py
index bfa9bfec01..60a4748606 100644
--- a/scripts/qapi/common.py
+++ b/scripts/qapi/common.py
@@ -1461,13 +1461,13 @@ class QAPISchema(object):
def __init__(self, fname):
try:
parser = QAPISchemaParser(open(fname, 'r'))
- self.exprs = check_exprs(parser.exprs)
+ exprs = check_exprs(parser.exprs)
self.docs = parser.docs
self._entity_dict = {}
self._predefining = True
self._def_predefineds()
self._predefining = False
- self._def_exprs()
+ self._def_exprs(exprs)
self.check()
except QAPIError as err:
print(err, file=sys.stderr)
@@ -1652,8 +1652,8 @@ class QAPISchema(object):
name, info, doc, 'arg', self._make_members(data, info))
self._def_entity(QAPISchemaEvent(name, info, doc, data, boxed))
- def _def_exprs(self):
- for expr_elem in self.exprs:
+ def _def_exprs(self, exprs):
+ for expr_elem in exprs:
expr = expr_elem['expr']
info = expr_elem['info']
doc = expr_elem.get('doc')