in reply to Why doesn't Perl find my heredoc terminator?

I'm guessing that the line that has the "EOF" in it has spaces before the EOF. Since you're telling perl that the heredoc will terminate with a line that matches /^EOF$/, and you don't have that line, perl complains.

Also, read on how to use <CODE> tags, to make your post more readable

-- Dan