Is there any way around this:
class B; class C { public: C() { } private: int i; friend B::B(); }; class B { public: B() { } private: int i
You just can't do this. Remove the circular dependency.