title: C++ std::vector with pointers to a template class
body: <p>In a project I am working on I am tying to make a vector with pointers to a template class.</p>
  
  <pre><code> template &lt;typename T&gt;
   std::vector&lt;templateClass&lt;T&gt;*&gt; vec;
  </code></pre>
  
  <p>However, this gives me two errors:</p>
  
  <pre><code>Error C2133: vec : unknown size
  Error C2998: std::vector&lt;templateClass&lt;T&gt;*&gt; vec : cannot be a template definition
  </code></pre>
  
  <p>If I change the code to:</p>
  
  <pre><code>std::vector&lt;templateClass&lt;int&gt;*&gt; vec;
  </code></pre>
  
  <p>It works fine, so I guess the problem isn't that you cant use template classes with vectors, but that you need to tell the compiler what type to use. Is there any way around this?</p>