Assume the following simple case (notice the location of virtual)
class A {
virtual void func();
};
class B : public A {
void func();
};
class C : public B {
void func();
};
Would the following call call B::func()
or C::func()
?
B* ptr_b = new C();
ptr_b->func();