Two objects that are not bit-fields may have the same address if one is a subobject of the other, or if at least one is a base class subobject of zero size and they are of different types;
不属于位域的两个对象可能拥有相同的地址(如果一个对象是另一个对象的子对象,或者至少有一个是空的基类子对象,并且他们的类型不同); 否则,他们应该在不同的地址上。
Two objects that are not bit-fields may have the same address if one is a subobject of the other, or if at least one is a base class subobject of zero size and they are of different types;
不属于位域的两个对象可能拥有相同的地址(如果一个对象是另一个对象的子对象,或者至少有一个是空的基类子对象,并且他们的类型不同); 否则,他们应该在不同的地址上。
应用推荐