summaryrefslogtreecommitdiff
path: root/tests/qapi-schema/struct-base-clash-base.json
diff options
context:
space:
mode:
Diffstat (limited to 'tests/qapi-schema/struct-base-clash-base.json')
-rw-r--r--tests/qapi-schema/struct-base-clash-base.json9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/qapi-schema/struct-base-clash-base.json b/tests/qapi-schema/struct-base-clash-base.json
new file mode 100644
index 0000000000..0c840258c9
--- /dev/null
+++ b/tests/qapi-schema/struct-base-clash-base.json
@@ -0,0 +1,9 @@
+# Struct member 'base'
+# FIXME: this parses, but then fails to compile due to a duplicate 'base'
+# (one explicit in QMP, the other used to box the base class members).
+# We should either reject the collision at parse time, or change the
+# generated struct to allow this to compile.
+{ 'struct': 'Base', 'data': {} }
+{ 'struct': 'Sub',
+ 'base': 'Base',
+ 'data': { 'base': 'str' } }