Skip to content

Instantly share code, notes, and snippets.

@christiannagel
Created April 5, 2013 19:38
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 christiannagel/5322007 to your computer and use it in GitHub Desktop.
Save christiannagel/5322007 to your computer and use it in GitHub Desktop.
C++11 lambda returning a value
auto l2 = [] {
return 42;
};
int x2 = l2();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment