On 23 July 2013 20:15, Peter Maydell <peter.mayd...@linaro.org> wrote:
> On 23 July 2013 03:43, Andreas Färber <afaer...@suse.de> wrote:
>> v2 improves internal vs. "public" header separation for GIC.
>> As before, no feedback was received to address PMM's QOM concerns,
>> so this is what we have as design patterns for the moment.
>
> I had a thought about this. Suppose we have our class header
> files do something like this:
>
> #ifdef MYCLASS_IMPLEMENTATION
> #define PRIVATE
> #else
> #ifdef __GNUC__
> #define PRIVATE __attribute__((deprecated("this is a private field")))
> #else
> #define PRIVATE
> #endif
>
> typedef struct MyObject {
>    int publicfield;
>    int privatefield PRIVATE;
> } MyObject;

Forgot to say, but if people don't think this is an
intrinsically terrible idea I'll put together a patch that
does this sometime this week.

-- PMM

Reply via email to