title: Inheriting constructors of template class in c++
body: <p>In c++11 it is possible to inherit constructors. I have the following code (reproducing example), which fails to compile:</p>
  
  <pre><code>template&lt;class T&gt; class A
  {
      ...
  }
  
  template&lt;class T&gt; class B : public A&lt;T&gt;
  {
      public:       
          B(int a, int b = 0);
  }
  template&lt;class T&gt; B::B(int a, int b /* =0 */)
  {
      ...
  }
  
  class C : public B&lt;int&gt;
  {
      public: 
      using B::B;
  }
  </code></pre>
  
  <p>The following code doesn't run with the error that <code>C</code> doesn't have the constructor, i.e. the one from <code>B</code> is not inherited:</p>
  
  <pre><code>C obj(5);
  //or
  C obj(5, 3);
  </code></pre>