Add condition to QAPIEvent enum members based on the event 'if'. Generated code is not changed by this patch, but with "qapi: add #if conditions to generated code" patch.
There is no coverage of this change in qapi-schema-test.out since the event_names enum is an implicit type created by qapi-event.py. Signed-off-by: Marc-André Lureau <marcandre.lur...@redhat.com> --- scripts/qapi/events.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/qapi/events.py b/scripts/qapi/events.py index ea4dac6a05..c9beef8b4b 100644 --- a/scripts/qapi/events.py +++ b/scripts/qapi/events.py @@ -189,7 +189,7 @@ class QAPISchemaGenEventVisitor(QAPISchemaModularCVisitor): self._genh.add(gen_event_send_decl(name, arg_type, boxed)) self._genc.add(gen_event_send(name, arg_type, boxed, self._enum_name)) - self._event_names.append(QAPISchemaMember(name)) + self._event_names.append(QAPISchemaMember(name, ifcond)) def gen_events(schema, output_dir, prefix): -- 2.18.0.rc1