http://www.perlmonks.org?node_id=915945

I was having a hard time understanding how to use POD documentation when I was habitually using block comments for all my documentation purposes. After reading the Perl Programming Documentation about POD, I found that, where I usually used comment blocks to describe functions, POD is just as effective if not more so. I then wondered, what is the purpose of commenting when POD exists (besides TMTOWTDI). I then realized that I should document my functions using POD and make small notes about the actual code using comments.

For example:

=pod =head2 mySubroutine Takes no argument. This is a sample example to show my idea about documentation using both comments and POD. =cut sub mySubroutine { print 'This is a sample subroutine.', "\n"; # prints this text because it's a simple example. } mySubroutine();

I hope this helps anyone who is just discovered POD and is either now confused about the purpose of both comments and POD or is looking for another method of documenting their code. If anyone has any comments (ha, comments), suggestions, or corrections for this node, please let me know!

Disclaimer:
This is what works for me, and, as always, TMTOWTDI.

"It's funny, the claw isn't what you should be worried about" -The Raven