in reply to Better ways to make multi-line comments in Perl?

A "not-really-comment" that may be used also as a usage message...
my $comment= <<END_COMMENT this is how my script works and this is why it doesn't work blah blah END_COMMENT ; # don't forget the final ";"
... then usage function may print the $comment variable

Replies are listed 'Best First'.
Re: Answer: Better ways to make multi-line comments in Perl?
by choroba (Cardinal) on Apr 25, 2014 at 15:18 UTC
    You can put the semicolon after the here-doc indicator:
    my $comment = << 'END_COMMENT'; Comment END_COMMENT
    لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ