perl switch statement limitation

Look at the documentation for the Perl switch statement. Look down the bottom at the "limitations" section. Look at the last limitation.

If your source file is longer then 1 million characters and you have a switch statement that crosses the 1 million (or 2 million, etc.) character boundary you will get mysterious errors. The workaround is to use smaller source files.

This article is © Adrian Smith.
It was originally published on 2 May 2007
More on: FAIL | Perl