One of the things I've been working on in KindaPerl6 is making it CPAN
ready, first by rewriting its custom Makefile as a Makefile.PL and
then by making various small fixes. Yesterday I wrote a unified
frontend to it (kp6(1)) and made `make install' work and released in
on CPAN as version 0.001.
Since KindaPerl6 is still in active and unstable development `make
test' does not run successfully at the moment. So the CPAN install has
to be forced:
cpan -f -i KindaPerl6
That should install KindaPerl6 along with its kp6 frontend, the hello
world example is then:
$ echo 'say "hello" ~ "world"' | kp6 | PERL5LIB=$(kp6 -lib) perl
helloworld
The PERL5LIB part is required so that the Perl 5 backend can find its
runtime libraries.
If you want to check out the AST of the program just do:
$ echo 'say "hello" ~ "world"' | kp6 -ast | perltidy
And to try another backend such as the Common Lisp one try one of the
emitter options:
$ echo 'say "hello" ~ "world"' | kp6 -lisp
There's no user friendly way to run the generated lisp code yet but
hopefully future releases will allow for passing options to specific
emitters. I'm hoping to make a user-friendly way to generate
stand-alone executables with sbcl from the command line for instance.

Recent Comments