http://qs321.pair.com?node_id=94977


in reply to Inline POD vs. EOF POD

Heh.. you reminded me of the joke:

Yes, I can write with either hand, I'm amphibious!

On a more serious note.. thats an excellent question you bring up, and I'd definitely like to see others opinions on the matter too.

Overall, I personally like inline POD better, from the coders point of view. The fact that it gets the code and documentation close together makes it much easier to keep both up to date. I'll often use POD to document my API's and such, instead of using normal comments. There are a lot of projects out there that readily admit to having poor documentation. With inline POD, there is often no excuse for such behaviour. That would be false laziness, and none of us Perl types would do that, right?? :-)

The problem with POD is that it's darn ugly. I appologize, I don't wish to badmouth it, but it really just is ugly :-) But I find that if you come up with a standard for how to use POD throughout your code to document functions and such, it can get easier to read with practice. Now, others reading your code will have to struggle with it at first.. but IMO, having up to date documentation is worth the added discomfort.
-Eric

Replies are listed 'Best First'.
Re: Re: Inline POD vs. EOF POD
by particle (Vicar) on Jul 09, 2001 at 18:26 UTC
    The problem with POD is that it's darn ugly. I appologize, I don't wish to badmouth it, but it really just is ugly :-)

    YES!!! not fifteen minutes ago was i muttering about the ugliness of POD. i'm in the final phase of a project for my current client, and i'm reviewing all the code and making sure the docs are updated as i turn everything over to the admin team. i use CodeWright for my editing, which does wonders to make perl code pleasant to look at, but does nothing to make pod code readable. i haven't taken the time to modify the lexer to color-code POD code, but i think i'll do just that after this job.

    but POD is ugly. i place mine at the end while i'm coding, because i hate to look at it. when i'm done with a program, usually i'll move it inline so whoever's maintaining the code is more likely to update the doc. (although i have no proof that putting the POD inline increases the likelyhood of maintenance, i do it anyway.)

    i tend to use well named variables and functions, and code comments to document my code. typically, i also generate detailed design documentation. sometimes i use pod to generate this, but lately i've found myself writing the doc and then cut/pasting the text into the script as pod. there, i've said it... pod's so ugly, i use Word instead! ACK. i feel dirty.

    ~Particle