Hi Robert,

On Wednesday 16 September 2009 03.28.52 Robert H wrote:
> When would you not use Inline instead of doing it with XS? For example,
> I am thinking about doing a wrapper for Metakit (ie DBD::Metakit). I
> talked with the author of Metakit and he said he tried to do a Perl
> wrapper in XS once but got lost. Is it feasible to do something like
> that using Inline instead or would XS be the best case scenario for a
> DBD module?


IMHO, there is absolutely no reason to use XS. Inline is flexible and allows 
for a more dynamic development.

I don't know what P6 will use, I think they were looking at something that was 
like the Python mechanism (I'd like pointer if someone has one). I don't 
understand why Inline wasn't made the default and XS relagated to the dark 
dungeon where it belongs.

We use Swig extensively at one of my former workplace it may be something you 
want to look into.

There are other ways to link libs into perl like dynamically loading them.

Good luck. 

PS: one of the things that I dislike with Inline C was the time it took to 
parse the code to find the functions to export to perl. I remember patching 
Inline to speed it up by bypassing the parsing altogether. It's somewhere in 
the Inline mailing list archive I believe.

Reply via email to