title: C++0x lambda, how can I pass as a parameter?
body: <p>Please look at the following C++0x lambda related code:</p>
  
  <pre><code>typedef uint64_t (*WEIGHT_FUNC)(void* param);
  typedef std::map&lt;std::string, WEIGHT_FUNC&gt; CallbackTable;
  
  CallbackTable table;
  table["rand_weight"] = [](void* param) -&gt; uint64_t
  {
    return (rand() % 100 + 1);
  };
  </code></pre>
  
  <p>I got an error (in Visual Studio 2010) that the lambda couldn't be converted to the type of <code>WEIGHT_FUNC</code>. I also know the answer: using <code>std::function object</code>:</p>
  
  <pre><code>typedef std::function&lt;uint64_t (void*)&gt;  WEIGHT_FUNC;
  </code></pre>
  
  <p>However, I also want to know how I can receive the type of lambda WITHOUT using <code>std::function</code>. What type should it be?</p>