title: Constructor inheritance in templated class (C++11)
body: <p>I have the following class definition:</p>
  
  <pre><code>template&lt;typename T&gt;
  class Point {
    private:
      T px, py;
    public:
      Point(T x, T y): px(x), py(y) {
        std::cout &lt;&lt; "created " &lt;&lt; x &lt;&lt; ":" &lt;&lt; y &lt;&lt;std::endl;
      };
      T x() const { return px; };
      T y() const { return py; };
  };
  </code></pre>
  
  <p>from which I am deriving specializations, e.g.</p>
  
  <pre><code>class PointScreen: public Point&lt;int&gt; {
    using Point::Point;
  };
  </code></pre>
  
  <p>When I compile this in <code>clang++</code>, I get no warning / error, but the constructor is not called:</p>
  
  <pre><code>#include &lt;iostream&gt;
  // definitions from above      
  int main() {
    std::cout &lt;&lt; PointScreen(100, 100).x() &lt;&lt; std::endl;
    return 0;
  }
  </code></pre>
  
  <p>This returns a random value (and also not the debug output "created..."). The value returned by e.g. <code>x()</code> is obviously "undefined".</p>
  
  <p>I have just tried the same in <code>g++</code> <a href="http://ideone.com/FdxXUx" rel="nofollow">here</a>, and there I obtain the expected result. Is this a problem with <code>clang++</code> or have I a bug in my code?</p>
  
  <p>My clang version: Ubuntu clang version 3.0-6ubuntu3 (tags/RELEASE_30/final) (based on LLVM 3.0). I compile with <code>-std=c++11 -Wall</code>.</p>