Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • I seem to get an error about an "undefined reference" when I try to use this solution, any ideas on what might be happening? Commented Nov 23, 2012 at 9:49
  • @noko, can you post you code to ideone or similar? Note you compiler must support C++11 lambdas (in g++ you need to use -std=c++0x compiler switch). Commented Nov 23, 2012 at 9:50
  • never mind, I forgot to add a ClassName:: before the function :( Commented Nov 23, 2012 at 9:58