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++/17519] [3.4/4.0 Regression] Warning for array of packed non-POD in packed struct


------- Additional Comments From nathan at gcc dot gnu dot org  2005-02-14 10:27 -------
The killer with packing in C++ is that it is so easy to silently take the
address of a field (pass by reference). Until we actually reflect unalignedness
in the type system *no* packing is really safe in C++.

That said, I don't see why the warning would be different for a packed non-array
member.

-- 


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


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