diff options
Diffstat (limited to 'scripts/qapi.py')
-rw-r--r-- | scripts/qapi.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/qapi.py b/scripts/qapi.py index 8edfd79c52..7dec611d09 100644 --- a/scripts/qapi.py +++ b/scripts/qapi.py @@ -940,7 +940,9 @@ class QAPISchemaObjectType(QAPISchemaType): self.members = None def check(self, schema): - assert self.members is not False # not running in cycles + if self.members is False: # check for cycles + raise QAPIExprError(self.info, + "Object %s contains itself" % self.name) if self.members: return self.members = False # mark as being checked |