Should this be called some special case of object slicing?
Let's say I have a class Derived which derives from class Base whereas sizeof(Derived) > sizeof(Base) . Now, if one allocates an array of Derived like this: Base * myArray = new Derived[42]; and then attempts to access the n -th object using doSomethingWithBase(myArray[n]); Then this is might likely (but not always) cause undefined behaviour due to accessing Base from an invalid location. What is the correct term for such an programming error? Should it be considered a case of object slicing ? This is not object slicing. As noted, indexing myArray does not cause object slicing, but results in