5 ms·
It can easily be done by declaring a prototype of B: // file: A.h class B; class A { B* _b; }; // file: B.h class B { A* _a; };
by green7ea 10y ago
It can easily be done by declaring a prototype of B:
// file: A.h
class B;
class A {
B* _b;
};
// file: B.h
class B {
A* _a;
};