Assuming that friendFunction() will ultimately need access to private parts of your Window class (it doesn't at the moment as Santosh Reddy points out)...
Line 14 of window.h is a grant of privileges, not a forward declaration of a function friendFunction(), which is what is needed in order for your implementation to compile. Add this line:
to the top of window.cpp. This forward declaration would typically be in a header included by the implementations that need to know that the function exists.
Bookmarks