title: Why use a new call with a C++ 'vector'?
body: <p>The code <code>vector&lt;someType&gt; myVector;</code> dynamically allocates memory, so any elements stored will live until a <code>delete</code> is called. So how is the following, <code>vector&lt;someType&gt; *myVector = new vector&lt;someType&gt;();</code>, different (other than being a pointer) from the earlier one?</p>
  <p>Is there a double allocation happening here?
  Everyone mentions it is evil to mix a <code>vector</code> with a <code>new</code> call, but why? If it is evil, why is it acceptable code for the compiler and when is it okay to use?</p>