This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/45510] Bug with anonymous unions and bit-fields



------- Comment #12 from runipg at broadcom dot com  2010-09-03 21:12 -------
Subject: Re:  Bug with anonymous unions and bit-fields

Okay, I guess I was confused by "struct or union" semantics. Thanks!


jakub at gcc dot gnu dot org wrote:
> ------- Comment #11 from jakub at gcc dot gnu dot org  2010-09-03 20:53 -------
> I don't see anything confusing about it.  If you have:
> union { int a, b, c; } u;
> u.a overlaps u.b and u.c as well, and the same applies to bitfields.  union
> isn't struct, see ISO C99 6.7.2.1/5.  The standard is clear on this.
>
>
>   


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45510


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]