fork download
  1. #include <iostream>
  2.  
  3. typedef int Type;
  4.  
  5. Type myFunction();
  6.  
  7. namespace foo {
  8.  
  9. class Foo
  10. {
  11. public:
  12. friend Type ::myFunction();
  13.  
  14. private:
  15. void bar() {}
  16. };
  17.  
  18. }
  19.  
  20. Type myFunction()
  21. {
  22. foo::Foo a;
  23. a.bar();
  24. return 0;
  25. }
  26.  
  27. int main() {
  28. // your code goes here
  29. return 0;
  30. }
Success #stdin #stdout 0s 3292KB
stdin
Standard input is empty
stdout
Standard output is empty