Indirect primary bases

Mark Mitchell mark at codesourcery.com
Sat Jul 29 20:05:19 UTC 2000


Why do we ever pick an indirect primary base as a primary base?

That doesn't save space in the object since the primary base we choose
was some other base's primary base.  Furthermore, we now have to
replicate that bases vtable entries in all the places where it is a
primary base.

What's the benefit?

If we can't think of one, I would suggest removing the last clause of:

  Otherwise, it is a nearly empty virtual base class, the first one in
  (preorder) inheritance graph order which is not an indirect primary
  base class if any exist, or just the first one if they are all
  indirect primaries.

--
Mark Mitchell                   mark at codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com




More information about the cxx-abi-dev mailing list