[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 23/33] qapi-commands: Inline gen_marshal_output_call(
From: |
Markus Armbruster |
Subject: |
[Qemu-devel] [PULL 23/33] qapi-commands: Inline gen_marshal_output_call() |
Date: |
Fri, 4 Sep 2015 16:21:30 +0200 |
Signed-off-by: Markus Armbruster <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
---
scripts/qapi-commands.py | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/scripts/qapi-commands.py b/scripts/qapi-commands.py
index 3965ca8..6de5229 100644
--- a/scripts/qapi-commands.py
+++ b/scripts/qapi-commands.py
@@ -57,19 +57,15 @@ def gen_sync_call(name, args, ret_type):
name=c_name(name), args=arglist, retval=retval).rstrip()
if ret_type:
ret += "\n" + gen_err_check('local_err')
- ret += "\n" + mcgen('''
-%(marshal_output_call)s
+ ret += mcgen('''
+
+qmp_marshal_output_%(c_name)s(retval, ret, &local_err);
''',
- marshal_output_call=gen_marshal_output_call(name,
ret_type)).rstrip()
+ c_name=c_name(name))
pop_indent()
return ret.rstrip()
-def gen_marshal_output_call(name, ret_type):
- if not ret_type:
- return ""
- return "qmp_marshal_output_%s(retval, ret, &local_err);" % c_name(name)
-
def gen_visitor_input_containers_decl(args):
ret = ""
--
2.4.3
- [Qemu-devel] [PULL 04/33] qapi-event: Clean up how name of enum QAPIEvent is made, (continued)
- [Qemu-devel] [PULL 04/33] qapi-event: Clean up how name of enum QAPIEvent is made, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 05/33] qapi: Reject -p arguments that break qapi-event.py, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 03/33] qapi: Simplify guardname(), Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 01/33] qapi: Clarify docs on including the same file multiple times, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 11/33] qapi-visit: Fix two name arguments passed to visitors, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 07/33] qapi: Fix generated code when flat union has member 'kind', Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 14/33] qapi: Document that input visitor semantics are prone to leaks, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 13/33] tests/qapi-schema: Document events with base don't work, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 15/33] qapi: Document shortcoming with union 'data' branch, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 06/33] qapi: Drop unused and useless parameters and variables, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 23/33] qapi-commands: Inline gen_marshal_output_call(),
Markus Armbruster <=
- [Qemu-devel] [PULL 27/33] qapi: Drop one of two "simple union must not have base" checks, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 25/33] qapi-commands: Drop useless initialization, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 02/33] qapi: Clean up cgen() and mcgen(), Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 22/33] qapi-commands: Fix gen_err_check(e) for e and e != 'local_err', Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 08/33] qapi: Generate a nicer struct for flat unions, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 12/33] tests/qapi-schema: Document alternate's enum lacks visit function, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 16/33] qapi: Document flaws in checking of names, Markus Armbruster, 2015/09/04
- [Qemu-devel] [PULL 30/33] qapi: Fix errors for non-string, non-dictionary members, Markus Armbruster, 2015/09/04