Multiple inheritance; destructors
If I have two base classes, GameObject and DrawableObject, and an object that inherits from both of these classes, like
class Thing : public GameObject, public DrawableObject
and I keep a pointer to an instance of Thing as a pointer to a GameObject like so:
GameObject *agameobject = new Thing;
If I delete it later on, calling delete on that agameobject pointer, will the DrawableObject destructor be called for the Thing, even though you can't tell by the pointer that the thing being pointed to is a DrawableObject? (all of the destructors are virtual)
Thanks in advance.