title: How should class fields be declared in C++?
body: <p>I need to declare and initialize a vector as a field of a class named <code>PixelOperator</code>.</p>
  
  <p>I am torn between these two declaration methods, the first is "on the heap", and the second "on the stack" (or at least, that is my interpretation).</p>
  
  <ol>
  <li><code>vector&lt;int&gt;* field = new vector&lt;int&gt;();</code></li>
  <li><code>vector&lt;int&gt; field = vector&lt;int&gt;();</code></li>
  </ol>
  
  <p>If I choose to declare in style number 1, I need to call delete in the destructor of the class.</p>
  
  <p>Which one should I choose, and why?</p>
  
  <p>Also, if the class is initialized on the heap (ie. <code>PixelOperator* op = new PixelOperator();</code>), are fields initialized on the stack initialized on the heap?</p>