Let's start by reviewing the way in which C++ grants friendship to classes, and the effects of this action, as well as when and for what reasons the friendship should be used (my code does not compile until I add friend everywhere is not a valid reason, but an indication of a poorly designed interface—redesign your classes instead).