diff options
author | Markus Armbruster <armbru@redhat.com> | 2015-09-16 13:06:21 +0200 |
---|---|---|
committer | Markus Armbruster <armbru@redhat.com> | 2015-09-21 09:56:48 +0200 |
commit | 56d92b003a223585980df5403ee9e3a55de90adf (patch) | |
tree | b9034dd5633dcff2ca8859ab4d6bb9991cfc26f2 /docs | |
parent | 03b4367a556179e3e59affa535493427bd009e9d (diff) |
qapi-commands: De-duplicate output marshaling functions
gen_marshal_output() uses its parameter name only for name of the
generated function. Name it after the type being marshaled instead of
its caller, and drop duplicates.
Saves 7 copies of qmp_marshal_output_int() in qemu-ga, and one copy of
qmp_marshal_output_str() in qemu-system-*.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Daniel P. Berrange <berrange@redhat.com>
Message-Id: <1442401589-24189-19-git-send-email-armbru@redhat.com>
Diffstat (limited to 'docs')
-rw-r--r-- | docs/qapi-code-gen.txt | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/qapi-code-gen.txt b/docs/qapi-code-gen.txt index 50da1d08b8..0884b5813c 100644 --- a/docs/qapi-code-gen.txt +++ b/docs/qapi-code-gen.txt @@ -721,7 +721,7 @@ Example: $ cat qapi-generated/example-qmp-marshal.c [Uninteresting stuff omitted...] - static void qmp_marshal_output_my_command(UserDefOne *ret_in, QObject **ret_out, Error **errp) + static void qmp_marshal_output_UserDefOne(UserDefOne *ret_in, QObject **ret_out, Error **errp) { Error *local_err = NULL; QmpOutputVisitor *mo = qmp_output_visitor_new(); @@ -764,7 +764,7 @@ Example: goto out; } - qmp_marshal_output_my_command(retval, ret, &local_err); + qmp_marshal_output_UserDefOne(retval, ret, &local_err); out: error_propagate(errp, local_err); |