我所经历的大文章上C++ POD, Trivial and Standard Layout classes 一个特性我还没有清楚地理解有关标准布局如下: -标准布局的C++
A standard layout has no base classes of the same type as the first
non-static data member
所以下面将不会是一个标准的布局,因为它有第一构件相同的基类
struct NonStandardLayout3 : StandardLayout1 {
StandardLayout1 x; // first member cannot be of the same type as base
};
但性能代价和属性明智如何在上述结构的任何比
不同这是上面这个的修正。
相关[post](http://stackoverflow.com/q/7160901/183120)。 – legends2k