   Class::Class*, how?
  Howdy,I'm using a chershire-cat-tesque system to hide my data from the interface class in some stuff that I'm working on.Basically put, all of my interface classes have the following lines in their declaration at the end:class Test{//for the actual question later onfriend class Test2;//this bitprivate:  class Implementation;  Implementation* implementation;};Now, the implementations are valid etc.  But I have one class that is tightly related to another and needs access to its implementation data.  I made the second class a friend of the first, but get errors on the following code:class Test;class Test::Implementation;class Test2{private:  void func(Test::Implementation* impl); //errors about Test and Test::Implementation not being defined.};Is there any way to provide this functionality, outside of making it void* and messing everything up?--CJM   
Quote:Original post by CJMIs there any way to provide this functionality, outside of making it void* and messing everything up?Have Test2.hpp #include Test.hpp (Test.Implementation.hpp need not be included).Alternatively, rename Test::Implementation to ::TestImplementation and have Test::Implementation typedefed to that.(There may be a legal syntax for forward-declaring Test::Implementation without defining all of Test, but I'm unaware of it if there is).   ;  No, there's not.   ;  Thanks,Turns out I just made a silly mistake, and included Test2.h in Test.h, in addition to including Test.h in Test2.h...  Ah well, thanks for your helps.--CJM   