From: "Andreas Färber" <afaerber@suse.de>
To: "Michael S. Tsirkin" <mst@redhat.com>
Cc: Peter Maydell <peter.maydell@linaro.org>,
Anthony Liguori <aliguori@us.ibm.com>,
Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>,
qemu-devel@nongnu.org, Blue Swirl <blauwirbel@gmail.com>
Subject: Re: [Qemu-devel] [PATCH] HACKING: remove bogus restrictions
Date: Tue, 28 Aug 2012 19:33:36 +0200 [thread overview]
Message-ID: <503D00F0.4040801@suse.de> (raw)
In-Reply-To: <20120828160116.GA3047@redhat.com>
Am 28.08.2012 18:01, schrieb Michael S. Tsirkin:
> We copied HACKING from libvirt but it has some bogus stuff:
> neither underscore capital, double underscore, or underscore 't' suffixes
> are reserved in Posix/C: this appears to be based on misreading of the
> C standard. Using sane prefixes is enough to avoid conflicts.
>
> These rules are also widely violated in our codebase,
> and it does not make sense to rework it all, apparently for
> no benefit.
It was generally not accepted to do Coding Style cleanups in the code
base so you will find lots of violations for any rule if you invest the
time to search. That's no reason to abolish any such rule.
Cc'ing malc, who has "violently" fought for this particular rule.
I also think that asking people not to introduce new ..._t typedefs is
different from asking to use appropriate existing typedefs, so HACKING
is not really contradicting itself in that aspect.
Regards,
Andreas
>
> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
> ---
> HACKING | 4 ----
> 1 file changed, 4 deletions(-)
>
> diff --git a/HACKING b/HACKING
> index 471cf1d..0a941fc 100644
> --- a/HACKING
> +++ b/HACKING
> @@ -69,10 +69,6 @@ it points to, or it is aliased to another pointer that is.
> 2.3. Typedefs
> Typedefs are used to eliminate the redundant 'struct' keyword.
>
> -2.4. Reserved namespaces in C and POSIX
> -Underscore capital, double underscore, and underscore 't' suffixes should be
> -avoided.
> -
> 3. Low level memory management
>
> Use of the malloc/free/realloc/calloc/valloc/memalign/posix_memalign
>
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
prev parent reply other threads:[~2012-08-28 17:33 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-28 16:01 [Qemu-devel] [PATCH] HACKING: remove bogus restrictions Michael S. Tsirkin
2012-08-28 16:07 ` Michael S. Tsirkin
2012-08-28 16:24 ` Peter Maydell
2012-08-28 17:18 ` Michael S. Tsirkin
2012-08-28 17:23 ` Peter Maydell
2012-08-28 17:32 ` Michael S. Tsirkin
2012-08-28 17:46 ` Peter Maydell
2012-08-28 18:00 ` Michael S. Tsirkin
2012-08-28 17:27 ` malc
2012-08-28 17:13 ` Blue Swirl
2012-08-28 17:21 ` Michael S. Tsirkin
2012-08-28 17:25 ` Blue Swirl
2012-08-28 17:27 ` Peter Maydell
2012-08-28 17:33 ` malc
2012-08-28 17:35 ` Michael S. Tsirkin
2012-08-28 17:34 ` Michael S. Tsirkin
2012-08-28 17:33 ` Andreas Färber [this message]
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=503D00F0.4040801@suse.de \
--to=afaerber@suse.de \
--cc=aliguori@us.ibm.com \
--cc=blauwirbel@gmail.com \
--cc=mst@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@linux.vnet.ibm.com \
/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).