Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int __cdecl _purecall(void)
- int __cdecl _purecall(void)
- class A
- {
- A *pThis;
- public:
- A()
- : pThis(this)
- {
- }
- void callFoo()
- {
- pThis->foo(); // call through the pThis ptr which was initialized in the constructor
- }
- virtual void foo() = 0;
- };
- class B : public A
- {
- public:
- virtual void foo()
- {
- }
- };
- B b();
- b.callFoo();
Add Comment
Please, Sign In to add comment