| 20 | }; |
| 21 | |
| 22 | class B : virtual public A |
| 23 | { |
| 24 | public: |
| 25 | void show() { |
| 26 | cout << "B::show()" << endl; |
| 27 | } |
| 28 | |
| 29 | void* operator new(size_t size) { |
| 30 | void *p = malloc(size); |
| 31 | cout << "operator new p: " << p << endl; |
| 32 | return p; |
| 33 | } |
| 34 | |
| 35 | void operator delete(void *ptr) { |
| 36 | cout << "B::opeartor delete p: " << ptr << endl; |
| 37 | free(ptr); |
| 38 | } |
| 39 | private: |
| 40 | int mb; |
| 41 | }; |
| 42 | |
| 43 | |
| 44 | int main() |
nothing calls this directly
no outgoing calls
no test coverage detected