title: C++ functor binding
body: <p>i tried to use the old bind2nd function in this way:</p>
  
  <pre><code>template&lt;typename T&gt;
  class printer
  {
  public:
    void operator()(T a, string&amp; kd)
    {
          cout&lt;&lt;a&lt;&lt;endl;
    }
  };
  
  
  int main(int argc, char *argv[])
  {
     string nme = "J-dar";
     auto f1 = bind2nd(printer&lt;int&gt;(),nme);
  
     //f1(5);
     return 0;
  }
  </code></pre>
  
  <p>but i get a lot of errors:</p>
  
  <pre><code>required from here
  error: no type named 'first_argument_type' in 'class printer&lt;int&gt;'  class binder2nd        ^
  error: no type named 'second_argument_type' in 'class printer&lt;int&gt;'    typename _Operation::second_argument_type value;                                              ^
  error: no type named 'second_argument_type' in 'class printer&lt;int&gt;'    binder2nd(const _Operation&amp; __x,    ^
  error: no type named 'result_type' in 'class printer&lt;int&gt;'    operator()(const typename _Operation::first_argument_type&amp; __x) const    ^
  error: no type named 'result_type' in 'class printer&lt;int&gt;'    operator()(typename      _Operation::first_argument_type&amp; __x) const    ^
  required from here
  error: no type named 'second_argument_type' in 'class printer&lt;int&gt;'    typedef typename _Operation::second_argument_type _Arg2_type;                                           
  </code></pre>
  
  <p>from what i can see it's all correct so i don't really know what is going on.           ^</p>