From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54183) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMsAC-0000du-UU for qemu-devel@nongnu.org; Wed, 05 Aug 2015 02:26:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZMsA9-0004sY-NF for qemu-devel@nongnu.org; Wed, 05 Aug 2015 02:26:56 -0400 Received: from mx1.redhat.com ([209.132.183.28]:38607) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMsA9-0004sR-Hn for qemu-devel@nongnu.org; Wed, 05 Aug 2015 02:26:53 -0400 From: Markus Armbruster References: <1438703896-12553-1-git-send-email-armbru@redhat.com> <1438703896-12553-6-git-send-email-armbru@redhat.com> <55C13E38.5060403@redhat.com> Date: Wed, 05 Aug 2015 08:26:51 +0200 In-Reply-To: <55C13E38.5060403@redhat.com> (Eric Blake's message of "Tue, 4 Aug 2015 16:35:36 -0600") Message-ID: <87a8u6uu6s.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH RFC v3 05/32] tests/qapi-schema: Convert test harness to QAPISchemaVisitor List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: kwolf@redhat.com, berto@igalia.com, qemu-devel@nongnu.org, mdroth@linux.vnet.ibm.com Eric Blake writes: > On 08/04/2015 09:57 AM, Markus Armbruster wrote: >> The old code prints the result of parsing (list of expression >> dictionaries), and partial results of semantic analysis (list of enum >> dictionaries, list of struct dictionaries). >> >> The new code prints a trace of a schema visit, i.e. what the back-ends >> are going to use. Built-in and array types are omitted, because >> they're boring. > > Array types might be less boring in the future when we fix the TODO > about unconditional array type generation - but that is in the realm of > the future and doesn't affect this patch. > >> >> Signed-off-by: Markus Armbruster >> --- >> tests/qapi-schema/alternate-good.out | 15 +- >> tests/qapi-schema/args-member-array.out | 13 +- >> tests/qapi-schema/comments.out | 4 +- >> tests/qapi-schema/empty.out | 3 - >> tests/qapi-schema/enum-empty.out | 4 +- >> tests/qapi-schema/event-case.out | 4 +- >> tests/qapi-schema/flat-union-reverse-define.out | 21 ++- >> tests/qapi-schema/ident-with-escape.out | 7 +- >> tests/qapi-schema/include-relpath.out | 4 +- >> tests/qapi-schema/include-repetition.out | 4 +- >> tests/qapi-schema/include-simple.out | 4 +- >> tests/qapi-schema/indented-expr.out | 7 +- >> tests/qapi-schema/qapi-schema-test.out | 214 >> ++++++++++++++++++------ >> tests/qapi-schema/returns-int.out | 5 +- >> tests/qapi-schema/test-qapi.py | 38 ++++- >> tests/qapi-schema/type-bypass.out | 7 +- >> 16 files changed, 239 insertions(+), 115 deletions(-) > > I don't know if you wanted to hoist the creation of the ':empty' object > into this patch, for less churn later on. But if you don't, I'm fine Again, out of time. > with leaving this alone. > > Reviewed-by: Eric Blake Thanks! >> +++ b/tests/qapi-schema/qapi-schema-test.out >> @@ -1,55 +1,159 @@ > >> +object :obj-boolList-wrapper >> + member data: boolList optional=False > ... >> +object UserDefNativeListUnion >> + case integer: :obj-intList-wrapper > > Simple unions turned out nicely with the generated wrapper type. Thanks for making me try harder there. It's more churn than I would like, but the resulting improvement feels right.