From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47454) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZNE6f-0000bL-2b for qemu-devel@nongnu.org; Thu, 06 Aug 2015 01:52:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZNE6b-0003Tg-OR for qemu-devel@nongnu.org; Thu, 06 Aug 2015 01:52:45 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59478) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZNE6b-0003Tc-JN for qemu-devel@nongnu.org; Thu, 06 Aug 2015 01:52:41 -0400 From: Markus Armbruster References: <1438703896-12553-1-git-send-email-armbru@redhat.com> <1438703896-12553-19-git-send-email-armbru@redhat.com> <55C23640.8050405@redhat.com> Date: Thu, 06 Aug 2015 07:52:38 +0200 In-Reply-To: <55C23640.8050405@redhat.com> (Eric Blake's message of "Wed, 5 Aug 2015 10:13:52 -0600") Message-ID: <87d1z1j74p.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [PATCH RFC v3 18/32] qapi: Replace dirty is_c_ptr() by method c_null() 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:58 AM, Markus Armbruster wrote: >> is_c_ptr() looks whether the end of the C text for the type looks like >> a pointer. Works, but is fragile. >> >> We now have a better tool: use QAPISchemaType method c_null(). The >> initializers for non-pointers become prettier: 0, false or the >> enumeration constant with the value 0 instead of {0}. >> >> One place looks suspicious: we initialize pointers, but not >> non-pointers. Either the initialization is superfluous and should be >> deleted, or the non-pointers need it as well, or something subtle is >> going on and needs a comment. Since I lack the time to figure it out >> now, mark it FIXME. > > Dead paragraph. The pre KVM Forum time crunch shows %-} Will drop. >> Signed-off-by: Markus Armbruster >> --- >> scripts/qapi-commands.py | 16 +++++----------- >> scripts/qapi.py | 3 --- >> 2 files changed, 5 insertions(+), 14 deletions(-) >> > > With fixed commit message, > Reviewed-by: Eric Blake Thanks!