In perl it's a heredoc.

You use << instead of <<<, and you need to specify EXACTLY what you put AFTER the << as the terminator.

So, in the example you posted, you would put
$foo=<<EOD
...
EOD;

You can't have spaces before the EOD; terminator unless the same number of spaces also follows the <<.

-Jeff Lowrey

At 05:15 PM 2/18/2005, Christopher L. Filkins wrote:
I'm looking for the perl equivalent of a heredoc declaration.  For some
reason I can't recall how.  In php it would work like this:

$foo = <<< EOD

Stuff stuff stuff

EOD;

I need to declare a several line string in a quick and easy fashion.  Any
ideas?

Christopher




Reply via email to