title: Memory leaks on expanding pre-allocated list through index
body: <p>I have a pre-allocated list that I use in my code:</p>
  
  <pre><code>slopeList &lt;-  vector('list',20)
  </code></pre>
  
  <p>When I copied/paste the code in the Rconsole I noticed that I could add more 
  records then allocated without any error nor warning.</p>
  
  <pre><code>for (i in (200:220)) slopeList[[i]]&lt;- 0
  </code></pre>
  
  <p>This runs without error nor warning. On the opposite entering manually the following line:</p>
  
  <pre><code>slopeList[[230]]
  </code></pre>
  
  <p><code>Error in slopeList[[230]] : subscript out of bounds</code>
  So the FOR loop could create a memory leak. </p>
  
  <p>Is there a flag that I can set in my program to generate warnings or errors even if the list is accessed in a loop?</p>