Skip to content

Instantly share code, notes, and snippets.

@moyang
moyang / VTable Notes on Multiple Inheritance in GCC C++ Compiler v4.0.1.md
Last active November 27, 2023 13:10
VTable Notes on Multiple Inheritance in GCC C++ Compiler v4.0.1

VTable Notes on Multiple Inheritance in GCC C++ Compiler v4.0.1

http://www.cse.wustl.edu/~mdeters/seminar/fall2005/mi.html#basics

The Basics: Single Inheritance

As we discussed in class, single inheritance leads to an object layoutwith base class data laid out before derived class data. So if classes A and B are defined as: