mirror of
https://github.com/yuzu-emu/unicorn.git
synced 2024-12-23 13:05:28 +00:00
qapi: ensure stable sort ordering when checking QAPI entities
Some early python 3.x versions will have different default ordering when calling the 'values()' method on a dict, compared to python 2.x and later 3.x versions. Explicitly sort the items to get a stable ordering. Backports commit f7a5376d4b667cf6c83c1d640e32d22456d7b5ee from qemu
This commit is contained in:
parent
74091c5976
commit
4fb711df46
|
@ -1684,7 +1684,7 @@ class QAPISchema(object):
|
||||||
assert False
|
assert False
|
||||||
|
|
||||||
def check(self):
|
def check(self):
|
||||||
for ent in self._entity_dict.values():
|
for (name, ent) in sorted(self._entity_dict.items()):
|
||||||
ent.check(self)
|
ent.check(self)
|
||||||
|
|
||||||
def visit(self, visitor):
|
def visit(self, visitor):
|
||||||
|
|
Loading…
Reference in a new issue