[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v4 08/16] qapi: Tidy c_type logic

From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH v4 08/16] qapi: Tidy c_type logic
Date: Thu, 14 May 2015 18:13:59 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Eric Blake <address@hidden> writes:

> On 05/14/2015 06:50 AM, Eric Blake wrote:
>> c_type() is designed to be called on both string names and on
>> array designations, so 'name' is a bit misleading because it
>> operates on more than strings.  Also, no caller ever passes
>> an empty string.  Finally, + notation is a bit nicer to read
>> than '%s' % value for string concatenation.
>> Signed-off-by: Eric Blake <address@hidden>
>> ---
>>      else:
>> -        return '%s *%s' % (name, eatspace)
>> +        # complex type name
>> +        assert isinstance(value, str) and str != ""
> D'oh - that should be 'value != ""'.

You're right!  Missed it in my review...  I'll fix it up on commit.
While there, I'll indulge in a bit of OCD and append () to c_type in the
subject, if you don't mind.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]