[cfe-dev] Fwd: Review of transparent_union patch

Eli Friedman eli.friedman at gmail.com
Sat Jan 24 12:57:04 PST 2009


On Fri, Jan 23, 2009 at 1:52 PM, Anders Johnsen <skabet at gmail.com> wrote:
>> 2. The way the attribute is getting attached looks wrong; this is a
>> union attribute, so it's required to appear immediately after the
>> definition of the union.  I suppose that's mostly orthogonal to this
>> patch, though.
>
> What exactly do you mean by this?

Something like the following:
struct x {int x; int* y;};
typedef struct x a __attribute((transparent_union));

This isn't valid, but it looks like your patch accepts it.

-Eli



More information about the cfe-dev mailing list