After seeing the article on Extending Ruby with C, I thought "I wonder how easy that would be in Perl?" The article is mostly about providing access to the Genx library. So, I spent a little while playing with it and came up XML::Genx. I don't know whether Perl needed another XML writing library; XML::SAX::Writer is pretty good. But Genx has some really useful features.
Anyway, it's been an interesting exercise. My C skills needed bringing out of storage, although I made few really daft mistakes. XS is still an "interesting" tool to work with. Coding at that level certainly makes you appreciate how high level Perl is.
On the whole though, the most useful surprise has been CPAN Testers. That's a really good way to find out that the world isn't just as FreeBSD faced as it looks like to me. Now all I need to do is figure out how to get a development environment working under windows.
Small World... (Score:1)
Re:Small World... (Score:2)
The other thing I really admire about the ruby version is the block syntax. Of course, it's possible in Perl, just ugly. And no, I refuse to use a source filter.
But yes, thanks for the inspiration!
-Dom
Re:Small World... (Score:1)
And get output like this:
This also caches elements and attributes so they don't get recreated each time through, and it a
Re:Small World... (Score:2)
That said, it's one of those things that I'm sure I'll find a use for before long, probably at work.
-Dom
Re:Small World... (Score:2)
-Dom