strlen Considered Dangerous

A user complained that when he loaded a particular PHP file into Komodo, the editor would become unresponsive, and there would be no code intelligence. A quick check outside the editor showed most of what I needed to know about this file:

  $ wc bug101267a-long-lines.php
  29 184833 735218 bug101267a-long-lines.php

The file consisted of the PHP header, a 28-line license, and a single line of code that, as you can see, was about 735K characters long.