I was just reading in ziggy's journal that some people wanted to replace POD with XML because XML is sexier. And well, I'm an XML guy, so you'd think I'd be all for that.
I'm not. But not why you might think I'm not.
Let me just say right out that POD sucks. It really really sucks. It is fantastic though for what it was designed for, unfortunately it was really designed in Perl 4's day, and so while it's kinda good at documenting a module or script with a few functions, it's pretty bad at documenting an OO module with parameters and a class hierarchy, and so on.
POD is also pretty bad for extensibility - so many people have tried to add things like footnotes or tables to POD, and most have failed pretty badly.
Finally, and this really is the biggy: the POD spec is like the Perl spec. Non-existant. And yet there's many POD parsers (and only one Perl parser - perl), and they probably all get it wrong (despite the release of perlpodspec.pod). Take L... you can actually parse the same L different ways depending on what spec you read. And if you parse it the way perlpodspec says, you break documents in the wild...
XML solves all of these problems. But, it doesn't solve some of the problems that POD *does* solve, such as being easy to author (I know *I* find XML easy to author, but most other people don't (and you don't count, robin!)).
What I'd personally advocate is a better plugability layer for docs than =begin. That would allow us XML geeks to have tons of metadata that most people couldn't give a shit about. The plugability layer should work like an XML parser in many ways - where you get more information if more information is available, and it should work like SAX in some ways - it should present the same API to the user no matter what "plugin" doc format they've decided to use.
Anyway, I guess I've become one of ziggy's hated "ideas" people rather than an implementor
POD isnt' so bad (Score:2)
Considering that one has to write documentation *first* in order to use POD. Too much complexity in what should be simple isn't really addressing the problem of not enough people document their modules. It's like people bitching about CPAN.pm yet they are usually the ones who either don't have a version or never bothered to read the documentation on what the appropriate version string is supposed to be. Close to 40% of the modules on CPAN either lack a version or POD or both. This isn't something XML is rea
Re:POD isnt' so bad (Score:1)
I don't think Matt's idea was to add complexity. He wants to add power. Now, I know that the two often walk in pairs, the latter as the intention and the former as the result.
I'm not in the camp of people that want to make Perl's documentation XML-based [mpe.mpg.de] (though I've come closer to it since that post, mostly for "enterprise" stuff and not for core Perl) but I could definitely use some extra metadata. The ActiveState people have been working on that (IIRC) and I'd love to hear about the output of th
-- Robin Berjon [berjon.com]
Re:POD isnt' so bad (Score:1)
Try it some time!
"Hated" ideas people? (Score:2)
I remember a couple of years ago falling into the "Replace POD to XML" camp, until tchrist set me straight. I've also been painfully aw
Replace Parrot with a scheme engine? (Score:1)
Plenty of scepticism about the whole Perl 6 enterprise, but I've not seen the 'use scheme' thing.
Re:Replace Parrot with a scheme engine? (Score:2)
Maybe we need to nail the problem (Score:2)
It is deficient in some ways. L is just wrong. We could use
Re:Maybe we need to nail the problem (Score:2)
Re:Maybe we need to nail the problem (Score:1)
The way I see addressing the problem is to create a POD API (not sure if POM is the right thing - I think we'd miss a streaming API) such that we could rip out POD and replace it with XML, when we needed that sort of power (or choose markup language X). It would have to cope with some sort of extensibility mechanism like XML Namespaces, so that we could define metadata tags (I use tags in the loosest sense of the word - they could be POD formatting constructs) in a