From: Paolo Bonzini <pbonzini@redhat.com>
To: "Peter Maydell" <peter.maydell@linaro.org>,
"Andreas Färber" <afaerber@suse.de>
Cc: QEMU Developers <qemu-devel@nongnu.org>,
Anthony Liguori <aliguori@amazon.com>,
Patch Tracking <patches@linaro.org>
Subject: Re: [Qemu-devel] [PATCH v2 0/4] Allow QOM struct fields to be marked as private
Date: Fri, 23 May 2014 16:33:40 +0200 [thread overview]
Message-ID: <537F5C44.7060002@redhat.com> (raw)
In-Reply-To: <CAFEAcA_HArebPbmtSyZhdd25g=NOW-NPJPBmwUPZdK2azHDF1g@mail.gmail.com>
Il 23/05/2014 13:50, Peter Maydell ha scritto:
> On 23 May 2014 12:23, Andreas Färber <afaerber@suse.de> wrote:
>> Am 23.05.2014 13:13, schrieb Peter Maydell:
>>> Ping?
>>
>> I believe I remarked that in the example
>> typedef struct Foo {
>> would be more in line with our Coding Style and majority of users.
>>
>> Other than that, I have no objections and assumed you'll take it through
>> your arm queue.
>
> Oops, yes, I'd forgotten that conversation. I'll remove
> the newline preceding the '{' and am happy to put this
> through the target-arm queue.
Semi-serious proposal:
#define comma_if_empty_ ,
#define CPP_IFEMPTY(macro, t, f) CPP_IFEMPTY1(macro, t, f)
#define CPP_IFEMPTY1(value, t, f) CPP_IF2(comma_if_empty_##value, t, f)
#define CPP_IF2(comma_if_true, t, f) CPP_IF3(comma_if_true t, f)
#define CPP_IF3(_, v, ...) v
#define qom_private(macro) CPP_IFEMPTY(IMPLEMENTING_##macro,, QEMU_PRIVATE_ATTR)
To be used as:
qom_private(A9_SCU) MemoryRegion iomem;
Credit: https://plus.google.com/u/0/+LinusTorvalds/posts/9gntjh57dXt
Paolo
next prev parent reply other threads:[~2014-05-23 14:33 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-09 15:56 [Qemu-devel] [PATCH v2 0/4] Allow QOM struct fields to be marked as private Peter Maydell
2014-05-09 15:56 ` [Qemu-devel] [PATCH v2 1/4] Provide infrastructure for marking private QOM struct fields Peter Maydell
2014-05-09 15:56 ` [Qemu-devel] [PATCH v2 2/4] arm_gic: Use new qom_private macro to mark private fields Peter Maydell
2014-05-09 15:56 ` [Qemu-devel] [PATCH v2 3/4] a9scu: Use qom_private " Peter Maydell
2014-05-09 15:56 ` [Qemu-devel] [PATCH v2 4/4] arm11scu: " Peter Maydell
2014-05-23 11:13 ` [Qemu-devel] [PATCH v2 0/4] Allow QOM struct fields to be marked as private Peter Maydell
2014-05-23 11:23 ` Andreas Färber
2014-05-23 11:50 ` Peter Maydell
2014-05-23 14:33 ` Paolo Bonzini [this message]
2014-05-23 16:21 ` Peter Maydell
2014-05-23 17:13 ` Paolo Bonzini
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=537F5C44.7060002@redhat.com \
--to=pbonzini@redhat.com \
--cc=afaerber@suse.de \
--cc=aliguori@amazon.com \
--cc=patches@linaro.org \
--cc=peter.maydell@linaro.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).