Data Layout
Mark Mitchell
mark at codesourcery.com
Tue Dec 14 21:16:11 UTC 1999
Folks --
We've started implementing the C++ ABI in g++. Implementation
efforts tend to uncover a few rough edges in specifications, and the
draft ABI looks to be no exception. :-) We'll send along questions,
and suggested clarifications, as we encounter them. Picking these
kinds of nits is going to be important if the various implementations
are really going to interoperate.
Question:
Does the presence of a zero-width bit-field prevent a class from
being empty?
Suggested Resolution:
No. Amend the definition of an "empty class" to read:
A class with no non-static data members other than zero-width
bitfields, no virtual functions, no virtual base classes, and no
non-empty non-virtual base classes.
Amend the definition of a "nearly empty class" to read:
A class, the objects of which contain only a Vptr and zero-width
bitfields.
--
Mark Mitchell mark at codesourcery.com
CodeSourcery, LLC http://www.codesourcery.com
More information about the cxx-abi-dev
mailing list