I am writing a module called Inline.pm. It uses source filtering to pull
out pieces of C (for now) source code from within perl code. It then
compiles the code into a shared object (unless one already exists) and
DynaLoads the module. Inline will also create all of the parameter-stack
bindings for simple typemaps, just like XS (but without the mess :-)

It is meant to be a resonable alternative to XS. Does "Inline" seem like a
reasonable name?

SYNOPSIS
   package Foo;
   use Inline;

   print "2 + 2 = ", add(2, 2), "\n";

   INLINE :C {
   long add(long a, long b) {
       return a + b;
   }
   }

   INLINE :COBOL {
   ...
   }
   __END__






Reply via email to