title: Why is std::bind not working without placeholders in this example (member function)?
body: <p>For example, this is my member function (<code>do_it</code>):</p>
  
  <pre><code>class oops
  {
  public:
      void do_it(GtkWidget *widget, GdkEvent *event, gpointer data)
      {
          g_print ("Hi there :)\n");
      }
  };
  </code></pre>
  
  <p>... and i use <code>std::bind</code> to make it look like a non-member function:</p>
  
  <pre><code>oops o;
  std::function&lt;void(GtkWidget*, GdkEvent*, gpointer)&gt; f = std::bind(&amp;oops::do_it, o);
  </code></pre>
  
  <p>but it doesn't work, the following is the compiler errors message:</p>
  
  <pre><code>program.cc: In function ‘int main(int, char**)’:
  program.cc:69:85: error: conversion from ‘std::_Bind_helper&lt;false, void (oops::*)(_GtkWidget*, _GdkEvent*, void*), oops&amp;&gt;::type {aka std::_Bind&lt;std::_Mem_fn&lt;void (oops::*)(_GtkWidget*, _GdkEvent*, void*)&gt;(oops)&gt;}’ to non-scalar type ‘std::function&lt;void(_GtkWidget*, _GdkEvent*, void*)&gt;’ requested
     std::function&lt;void(GtkWidget*, GdkEvent*, gpointer)&gt; f = std::bind(&amp;oops::do_it, o);
                                                                                       ^
  </code></pre>
  
  <p>I have to fix it by using <code>std::placeholders</code>:</p>
  
  <pre><code>oops o;
  std::function&lt;void(GtkWidget*, GdkEvent*, gpointer)&gt; f = std::bind(&amp;oops::do_it, o, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3);
  </code></pre>
  
  <p>Why it doesn't work without specifying <code>std::placeholders</code>?</p>