Created
July 19, 2010 12:02
-
-
Save eed3si9n/481313 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
class Foo { | |
}; | |
class Bar { | |
private: | |
int m_number; | |
public: | |
Bar(Foo aFoo) { m_number = 7; } | |
int getNumber() { return m_number; } | |
}; | |
int doSomething(Bar aBar) { return aBar.getNumber(); } | |
int main() { | |
Foo foo; | |
cout << doSomething(foo) << endl; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment