qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v5 04/14] qapi: Adjust names of implicit types


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCH v5 04/14] qapi: Adjust names of implicit types
Date: Fri, 11 Mar 2016 10:29:26 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0

On 03/11/2016 12:48 AM, Markus Armbruster wrote:

>>>> time to change our naming convention; we can instead use the 'q_'
>>>> prefix that we reserved for ourselves back in commit 9fb081e0.  As
>>>> long as we don't declare 'empty' or 'obj' ticklish, it shouldn't
>>>> clash with c_name() prepending 'q_' to the user's ticklish names.
>>>
>>> Do we really want to rename :empty?  We're not going to generate C for
>>> it, are we?
>>
>> No, but it was easier to implement .is_implicit() as
>> "name.startswith('q_')" than as "name == ':empty' or
>> name.startswith('q_obj')".  I can stick with :empty if you want a
>> respin, though.
> 
> You avoid complicating .is_implicit() slightly, and you pay for that
> with a bit of patch churn elsewhere.  Sounds justified.
> 
> Is ':empty' the last use of the ':' prefix?

Yes.  And renaming it to 'q_empty' meant I didn't have to add ':' to the
set of characters to be transliterated in c_name().

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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