struct Y1 { virtual void foo() {} }; struct X : virtual Y1 { void foo(); }; void X::foo() { void* p = this; }