From: Eduardo Habkost <ehabkost@redhat.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: qemu-devel@nongnu.org, Michael Roth <mdroth@linux.vnet.ibm.com>
Subject: Re: [Qemu-devel] [PATCH v2 2/3] qapi: Add enum_table[] parameter to start_alternate
Date: Wed, 10 May 2017 10:38:02 -0300 [thread overview]
Message-ID: <20170510133802.GC3482@thinpad.lan.raisama.net> (raw)
In-Reply-To: <87a86k25tv.fsf@dusky.pond.sub.org>
On Wed, May 10, 2017 at 03:34:52PM +0200, Markus Armbruster wrote:
> Eduardo Habkost <ehabkost@redhat.com> writes:
>
> > The new parameter will be used by the string input visitor to detect
> > alternate types that can't be parsed unambiguously.
> >
> > Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
[...]
> > diff --git a/qapi/trace-events b/qapi/trace-events
> > index b15a55b797..384c251814 100644
> > --- a/qapi/trace-events
> > +++ b/qapi/trace-events
> > @@ -11,7 +11,7 @@ visit_next_list(void *v, void *tail, size_t size) "v=%p tail=%p size=%zu"
> > visit_check_list(void *v) "v=%p"
> > visit_end_list(void *v, void *obj) "v=%p obj=%p"
> >
> > -visit_start_alternate(void *v, const char *name, void *obj, size_t size, uint32_t supported_qtypes) "v=%p name=%s obj=%p size=%zu supported_qtypes=0x%x"
> > +visit_start_alternate(void *v, const char *name, void *obj, size_t size, uint32_t supported_qtypes, void *enum_table) "v=%p name=%s obj=%p size=%zu supported_qtypes=0x%x enum_table=%p"
> > visit_end_alternate(void *v, void *obj) "v=%p obj=%p"
> >
> > visit_optional(void *v, const char *name, bool *present) "v=%p name=%s present=%p"
>
> Not yet sure we need this, but if we do, clarify the function comment,
> and you may add
>
> Reviewed-by: Markus Armbruster <armbru@redhat.com>
Thanks.
The only reason for this patch is to allow code in patch 3/3 to
detect ambiguous enums at runtime. I don't think the runtime
detection solution looked good, though, so I will probably drop
this patch.
--
Eduardo
next prev parent reply other threads:[~2017-05-10 13:38 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-05 20:11 [Qemu-devel] [PATCH v2 0/3] string-input-visitor: Support enum/bool alternate types Eduardo Habkost
2017-05-05 20:11 ` [Qemu-devel] [PATCH v2 1/3] visitor: Add 'supported_qtypes' parameter to visit_start_alternate() Eduardo Habkost
2017-05-05 20:26 ` Eric Blake
2017-05-10 13:16 ` Markus Armbruster
2017-05-10 21:10 ` Eduardo Habkost
2017-05-11 7:04 ` Markus Armbruster
2017-05-05 20:11 ` [Qemu-devel] [PATCH v2 2/3] qapi: Add enum_table[] parameter to start_alternate Eduardo Habkost
2017-05-05 20:45 ` Eric Blake
2017-05-05 20:51 ` Eduardo Habkost
2017-05-10 13:34 ` Markus Armbruster
2017-05-10 13:38 ` Eduardo Habkost [this message]
2017-05-05 20:11 ` [Qemu-devel] [PATCH v2 3/3] string-input-visitor: Support alternate types Eduardo Habkost
2017-05-05 20:53 ` Eric Blake
2017-05-05 21:09 ` Eduardo Habkost
2017-05-10 13:45 ` Markus Armbruster
2017-05-10 13:43 ` Markus Armbruster
2017-05-05 20:42 ` [Qemu-devel] [PATCH v2 0/3] string-input-visitor: Support enum/bool " no-reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170510133802.GC3482@thinpad.lan.raisama.net \
--to=ehabkost@redhat.com \
--cc=armbru@redhat.com \
--cc=mdroth@linux.vnet.ibm.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.