------- Comment #2 from pinskia at gcc dot gnu dot org 2008-10-03 20:46 ------- In the private case, A is a non-POD so _c can fit tail part of A. So the sizeof(M) is 16 bytes. In the public case, A is a POD so _c is not allowed to be in the tail part of A (as required by the C++ standard), so the sizeof(M) is 2 * 16. The sizeof (_c) is 1 as required by the C++ standard.
For the non aligned case, there is no tail part of A for the non POD case as the alignment and size are equal. -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37715