[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RFC v3 05/32] scripts/qapi: add QAPISchemaVisitor.visit_module_end
From: |
marcandre . lureau |
Subject: |
[RFC v3 05/32] scripts/qapi: add QAPISchemaVisitor.visit_module_end |
Date: |
Tue, 7 Sep 2021 16:19:16 +0400 |
From: Marc-André Lureau <marcandre.lureau@redhat.com>
Used in following patches to generate code after visiting a module.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
scripts/qapi/schema.py | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/scripts/qapi/schema.py b/scripts/qapi/schema.py
index 1f6301c394..6455a8f425 100644
--- a/scripts/qapi/schema.py
+++ b/scripts/qapi/schema.py
@@ -128,6 +128,9 @@ def visit_end(self):
def visit_module(self, name):
pass
+ def visit_module_end(self, name) -> None:
+ pass
+
def visit_needed(self, entity):
# Default to visiting everything
return True
@@ -207,6 +210,7 @@ def visit(self, visitor):
for entity in self._entity_list:
if visitor.visit_needed(entity):
entity.visit(visitor)
+ visitor.visit_module_end(self.name)
class QAPISchemaInclude(QAPISchemaEntity):
--
2.33.0.113.g6c40894d24
- Re: [RFC v3 01/32] RFC: docs: add supported host CPUs section, (continued)
- [RFC v3 02/32] build-sys: add HAVE_IPPROTO_MPTCP, marcandre . lureau, 2021/09/07
- [RFC v3 03/32] scripts/qapi: teach c_param_type() to return const argument type, marcandre . lureau, 2021/09/07
- [RFC v3 04/32] glib-compat: add G_SIZEOF_MEMBER, marcandre . lureau, 2021/09/07
- [RFC v3 05/32] scripts/qapi: add QAPISchemaVisitor.visit_module_end,
marcandre . lureau <=
- [RFC v3 06/32] scripts/qapi: add a CABI module, marcandre . lureau, 2021/09/07
- [RFC v3 07/32] scripts/qapi: generate CABI dump for C types, marcandre . lureau, 2021/09/07
- [RFC v3 08/32] tests: build qapi-cabi (C ABI dump), marcandre . lureau, 2021/09/07
- [RFC v3 09/32] build-sys: add i686 cpu target, marcandre . lureau, 2021/09/07
- [RFC v3 10/32] build-sys: add --with-rust{-target} & basic build infrastructure, marcandre . lureau, 2021/09/07
- [RFC v3 11/32] build-sys: add a cargo-wrapper script, marcandre . lureau, 2021/09/07