title: Using continue in a do-while loop
body: <p><a href="https://developer.mozilla.org/en/Core_JavaScript_1.5_Guide/Statements#continue_Statement" rel="noreferrer">MDN states:</a></p>
  
  <blockquote>
    <p>When you use <code>continue</code> without a label, it terminates the current iteration of the innermost enclosing <code>while</code>, <code>do-while</code> or <code>for</code> statement and continues execution of the loop with the next iteration.</p>
  </blockquote>
  
  <p>I'm not sure why the following piece of code does not work as I expect.</p>
  
  <pre><code>do {
    continue;
  } while(false);
  </code></pre>
  
  <p>Even though the <code>while</code> condition is <code>false</code>, I expect it to run forever since <code>continue</code> jumps towards the start of the block, which immediately executes <code>continue</code> again, etc. Somehow however, the loop terminates after one iteration. It looks like <code>continue</code> is ignored.</p>
  
  <p>How does <code>continue</code> in a <code>do-while</code> loop work?</p>