title: Template inheritance and a base member variable
body: <p>I get a weird error when trying to use template inheritance.
  This is my code:</p>
  
  <pre><code>template &lt;class T&gt; class A {
  public:
      int a {2};
      A(){};
  };
  
  template &lt;class T&gt; class B : public A&lt;T&gt; {
      public:
      B(): A&lt;T&gt;() {};
      void test(){    std::cout &lt;&lt; "testing... " &lt;&lt; a &lt;&lt; std::endl;   };
  };
  </code></pre>
  
  <p>And this is the error:</p>
  
  <pre><code>error: use of undeclared identifier 'a'; did you mean 'std::uniform_int_distribution&lt;long&gt;::a'?
      void test(){    std::cout &lt;&lt; "testing... " &lt;&lt; a &lt;&lt; std::endl;   }
  </code></pre>
  
  <p>And in case it could affect something I use these flags:</p>
  
  <pre><code>-Wall -g -std=c++11
  </code></pre>
  
  <p>I really don't know what is wrong since the same code as pure classes without templating works fine.</p>