title: Why am i receiving this jsfiddle error, document.write can be a form of eval
body: <p>I am testing a code I found while reading a book. I get this error while testing it out in JS fiddle, <code>document.write</code> can be a form of eval.</p>
  
  <pre><code>     var text = '&lt;html&gt;&lt;body bgcolor=linen&gt;&lt;p&gt;' +
      'This is &lt;b&gt;bold&lt;\/b&gt;!&lt;\/p&gt;&lt;\/body&gt;&lt;\/html&gt;';
  
  var tags = /[^&lt;&gt;]+|&lt;(\/?)([A-Za-z]+)([^&lt;&gt;]*)&gt;/g;
  var a, i;
  while ((a = tags.exec(text))) {
      for (i = 0; i &lt; a.length; i += 1) {
          document.writeln(('// [' + i + '] ' + a[i]).entityify());
      }
      document.writeln();
  }   
  </code></pre>
  
  <p>I am getting the above JSfiddle warning on both lines with <code>document.writeln()</code>.</p>