title: std::vector size?
body: <p>Program:</p>
  
  <pre><code>#include&lt;vector&gt;
  
  int main() {
      std::vector&lt;int&gt;::size_type size=3;
      std::vector&lt;int&gt; v{size};
  }
  </code></pre>
  
  <p>when compiled with</p>
  
  <pre><code>g++ (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3
  </code></pre>
  
  <p>generates error:</p>
  
  <pre><code>ppp.cpp: In function ‘int main()’:
  ppp.cpp:5:28: error: narrowing conversion of ‘size’ from ‘std::vector&lt;int&gt;::size_type {aka long unsigned int}’ to ‘int’ inside { } [-fpermissive]
  ppp.cpp:5:28: error: narrowing conversion of ‘size’ from ‘std::vector&lt;int&gt;::size_type {aka long unsigned int}’ to ‘int’ inside { } [-fpermissive]
  </code></pre>
  
  <p>and on <a href="http://www.cplusplus.com/reference/stl/vector/vector/" rel="nofollow">http://www.cplusplus.com/reference/stl/vector/vector/</a> it is written </p>
  
  <pre><code>explicit vector ( size_type n, const T&amp; value= T(), const Allocator&amp; = Allocator() );
  </code></pre>
  
  <p>I expected that constructor to be used. </p>
  
  <p>Can somebody explain?</p>