Skip to content

Instantly share code, notes, and snippets.

@wess
Created August 18, 2010 18:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wess/535647 to your computer and use it in GitHub Desktop.
Save wess/535647 to your computer and use it in GitHub Desktop.
C++:
void Blah(int &someint)
{
someint++;
}
void playWithBlah()
{
int x = 0;
Blah(x);
printf("%d", x);
// X will print 1
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment