[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 05/17] qapi: Avoid use of 'data' member of qapi
From: |
Daniel P. Berrange |
Subject: |
Re: [Qemu-devel] [PATCH 05/17] qapi: Avoid use of 'data' member of qapi unions |
Date: |
Mon, 22 Feb 2016 10:34:47 +0000 |
User-agent: |
Mutt/1.5.24 (2015-08-30) |
On Fri, Feb 19, 2016 at 05:19:35PM -0700, Eric Blake wrote:
> qapi code generators currently create a 'void *data' member as
> part of the anonymous union embedded in the C struct corresponding
> to a qapi union. However, directly assigning to this member of
> the union feels a bit fishy, when we can directly use the rest
> of the struct instead.
>
> Signed-off-by: Eric Blake <address@hidden>
>
> ---
> v1: no change
> Previously posted as part of qapi cleanup series F:
> v6: rebase to latest
> ---
> blockdev.c | 31 +++++++++++++++++--------------
> ui/input.c | 2 +-
> 2 files changed, 18 insertions(+), 15 deletions(-)
Reviewed-by: Daniel P. Berrange <address@hidden>
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
- [Qemu-devel] [PATCH 15/17] qapi: Use anonymous base in SchemaInfo, (continued)
- [Qemu-devel] [PATCH 15/17] qapi: Use anonymous base in SchemaInfo, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 13/17] qapi-visit: Move error check into gen_visit_fields_call(), Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 16/17] qapi: Use anonymous base in CpuInfo, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 01/17] chardev: Properly initialize ChardevCommon components, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 11/17] qapi-visit: Simplify visit of empty branch in union, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 04/17] ui: Shorten references into InputEvent, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 05/17] qapi: Avoid use of 'data' member of qapi unions, Eric Blake, 2016/02/19
- Re: [Qemu-devel] [PATCH 05/17] qapi: Avoid use of 'data' member of qapi unions,
Daniel P. Berrange <=
- [Qemu-devel] [PATCH 03/17] util: Shorten references into SocketAddress, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 14/17] qapi: Allow anonymous base for flat union, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 17/17] qapi: Make c_type() more OO-like, Eric Blake, 2016/02/19
- [Qemu-devel] [PATCH 12/17] qapi: Don't special-case simple union wrappers, Eric Blake, 2016/02/19