struct A { }; struct B : public A {}; B *b; A *a1 = static_cast<::A *> (b); A *a2 = (::A *) (b);