Friend function: Difference between revisions

Content deleted Content added
Tags: Mobile edit Mobile web edit
Undid revision 844923572 by 2409:4052:607:50DD:3A90:6E43:8440:5200 (talk) unexplained content removal
Line 29:
private:
int b;
public:
Foo(): b(6) {}
friend void show(Bar& x, Foo& y); // declaration of global friend
friend void Bar::show(Bar& x, Foo& y); // declaration of friend from other class
};