qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH v9 13/27] qapi: Drop obsolete tag value collision as


From: Eric Blake
Subject: [Qemu-devel] [PATCH v9 13/27] qapi: Drop obsolete tag value collision assertions
Date: Tue, 3 Nov 2015 23:20:35 -0700

From: Markus Armbruster <address@hidden>

Union tag values can't clash with member names in generated C anymore
since commit e4ba22b, but QAPISchemaObjectTypeVariant.check() still
asserts they don't.  Drop it.

Signed-off-by: Markus Armbruster <address@hidden>
Message-Id: <address@hidden>
[A later patch will still need to pass vseen from Variants.check()
to Variant.check(), so to avoid churn, change the cleanup to occur
lower in Variant.check()]
Signed-off-by: Eric Blake <address@hidden>

---
v9: new patch
---
 scripts/qapi.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/qapi.py b/scripts/qapi.py
index a814e20..145dbfe 100644
--- a/scripts/qapi.py
+++ b/scripts/qapi.py
@@ -1067,7 +1067,7 @@ class 
QAPISchemaObjectTypeVariant(QAPISchemaObjectTypeMember):
         QAPISchemaObjectTypeMember.__init__(self, name, typ, False)

     def check(self, schema, tag_type, seen):
-        QAPISchemaObjectTypeMember.check(self, schema, [], seen)
+        QAPISchemaObjectTypeMember.check(self, schema, [], {})
         assert self.name in tag_type.values

     # This function exists to support ugly simple union special cases
-- 
2.4.3




reply via email to

[Prev in Thread] Current Thread [Next in Thread]