Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: Multi-line comments in perl code?

by ikegami (Pope)
on Jul 14, 2006 at 19:28 UTC ( #561305=note: print w/replies, xml ) Need Help??


in reply to Multi-line comments in perl code?

Analysis of Solutions (Yes = good)
Solution Optimized away Strict friendly Indentable directives Usable mid-statement
my $comment = <<'EOC'; bla bla EOC
No Yes No No
$comment = <<'EOC' if 0; bla bla EOC
Yes No* No No
0 && <<'EOC'; bla bla EOC
Yes Yes No No
0 && q{ ... };
(and variations)
Yes Yes Yes No
=for comment bla bla =cut
Yes Yes No Yes
# bla bla # bla bla # bla bla
Yes Yes Yes Yes

Judgements on readability left to you.

None of the above give warnings.

* — One cannot simply add my because the behaviour or my ... if 0; is undefined, and thus must not be used.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://561305]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (3)
As of 2020-08-14 15:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Which rocket would you take to Mars?










    Results (76 votes). Check out past polls.

    Notices?