Re: [RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-09-02 Thread Victor Toso
Hi, On Fri, Jun 17, 2022 at 02:19:26PM +0200, Victor Toso wrote: > This patch handles QAPI alternate types and generates data structures > in Go that handles it. > > At this moment, there are 5 alternates in qemu/qapi, they are: > * BlockDirtyBitmapMergeSource > * Qcow2OverlapChecks > *

Re: [RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-08-29 Thread Victor Toso
Hi, On Mon, Aug 29, 2022 at 01:27:06PM +0200, Markus Armbruster wrote: > Victor Toso writes: > > > Hi, > > > > On Fri, Aug 19, 2022 at 11:27:13AM -0500, Andrea Bolognani wrote: > >> On Wed, Aug 17, 2022 at 04:04:19PM +0200, Victor Toso wrote: > >> > On Tue, Jul 05, 2022 at 08:45:06AM -0700,

Re: [RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-08-29 Thread Markus Armbruster
Victor Toso writes: > Hi, > > On Fri, Aug 19, 2022 at 11:27:13AM -0500, Andrea Bolognani wrote: >> On Wed, Aug 17, 2022 at 04:04:19PM +0200, Victor Toso wrote: >> > On Tue, Jul 05, 2022 at 08:45:06AM -0700, Andrea Bolognani wrote: >> > > On Fri, Jun 17, 2022 at 02:19:26PM +0200, Victor Toso

Re: [RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-08-22 Thread Victor Toso
Hi, On Fri, Aug 19, 2022 at 11:27:13AM -0500, Andrea Bolognani wrote: > On Wed, Aug 17, 2022 at 04:04:19PM +0200, Victor Toso wrote: > > On Tue, Jul 05, 2022 at 08:45:06AM -0700, Andrea Bolognani wrote: > > > On Fri, Jun 17, 2022 at 02:19:26PM +0200, Victor Toso wrote: > > > > func (s

Re: [RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-08-19 Thread Andrea Bolognani
On Wed, Aug 17, 2022 at 04:04:19PM +0200, Victor Toso wrote: > On Tue, Jul 05, 2022 at 08:45:06AM -0700, Andrea Bolognani wrote: > > On Fri, Jun 17, 2022 at 02:19:26PM +0200, Victor Toso wrote: > > > func (s *BlockdevRef) UnmarshalJSON(data []byte) error { > > > // Check for json-null first >

Re: [RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-08-17 Thread Victor Toso
Hi, On Tue, Jul 05, 2022 at 08:45:06AM -0700, Andrea Bolognani wrote: > Sorry it took me a while to find the time to look into this! (1.5 month later.. what can I say!) :) > Overall this second iteration is a significant improvement over the > initial one. There are still a few things that I

Re: [RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-07-05 Thread Andrea Bolognani
Sorry it took me a while to find the time to look into this! Overall this second iteration is a significant improvement over the initial one. There are still a few things that I think should be changed, so for the time being I'm going to comment mostly on the generated Go code and leave the

[RFC PATCH v2 2/8] qapi: golang: Generate qapi's alternate types in Go

2022-06-17 Thread Victor Toso
This patch handles QAPI alternate types and generates data structures in Go that handles it. At this moment, there are 5 alternates in qemu/qapi, they are: * BlockDirtyBitmapMergeSource * Qcow2OverlapChecks * BlockdevRef * BlockdevRefOrNull * StrOrNull Alternate types are similar to Union