qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Anthony Liguori <anthony@codemonkey.ws>
To: Avi Kivity <avi@redhat.com>
Cc: qemu-devel@nongnu.org, kvm@vger.kernel.org
Subject: Re: [Qemu-devel] [PATCH] Introduce short names for fixed width integer types
Date: Mon, 08 Aug 2011 08:17:03 -0500	[thread overview]
Message-ID: <4E3FE1CF.2010203@codemonkey.ws> (raw)
In-Reply-To: <4E3FE0B7.3090805@redhat.com>

On 08/08/2011 08:12 AM, Avi Kivity wrote:
> On 08/08/2011 04:00 PM, Anthony Liguori wrote:
>> On 08/08/2011 07:56 AM, Avi Kivity wrote:
>>> QEMU deals with a lot of fixed width integer types; their names
>>> (uint64_t etc) are clumsy to use and take up a lot of space.
>>>
>>> Following Linux, introduce shorter names, for example U64 for
>>> uint64_t.
>>
>> Except Linux uses lower case letters.
>>
>> I personally think Linux style is wrong here. The int8_t types are
>> standard types.
>>
>> Besides, we save lots of characters by using 4-space tabs instead of
>> 8-space tabs. We can afford to spend some of those saved characters on
>> using proper type names :-)
>>
>
> It's not about saving space, it's about improving readability. We have
> about 21k uses of these types, they deserve short names.

This is one of the few areas that we're actually consistent with today. 
  Introducing a new set of types will just create inconsistency.

Most importantly, these are standard types.  Every modern library and C 
program should be using them.  TBH, having short names is just a bad 
case of NIH.

Regards,

Anthony Liguori

  reply	other threads:[~2011-08-08 13:17 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-08 12:56 [Qemu-devel] [PATCH] Introduce short names for fixed width integer types Avi Kivity
2011-08-08 13:00 ` Anthony Liguori
2011-08-08 13:12   ` Avi Kivity
2011-08-08 13:17     ` Anthony Liguori [this message]
2011-08-08 13:19       ` Avi Kivity
2011-08-08 14:17   ` Kevin Wolf
2011-08-08 13:19 ` Peter Maydell
2011-08-09 10:18   ` malc
2011-08-09 12:39   ` Juan Quintela

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E3FE1CF.2010203@codemonkey.ws \
    --to=anthony@codemonkey.ws \
    --cc=avi@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).