Inline::Perl6 - use the real Perl 6 from Perl 5 code
use Inline::Perl6; my $p6 = Inline::Perl6->new; $p6->run("use Test; ok(1);"); $p6->run("use Test; ok(2); done-testing();"); $p6->use('Foo'); my $foo = $p6->invoke('Foo', 'new'); my $baz = $foo->bar('baz');
This module embeds a MoarVM based Rakudo Perl 6 and allows you to run Perl 6 code, load Perl 6 modules, use methods of Perl 6 objects and much more.
This module requires an up to date Rakudo with an enabled MoarVM backend. The perl6 executable needs to be in your PATH when you run Makefile.PL. You need to install the Inline::Perl5 Perl 6 module which this module is based on. You may do this using the "panda" Perl 6 module installer:
panda install Inline::Perl5 perl Makefile.PL make make test make install
Please note that if you have multiple perl installations (e.g. with perlbrew), you have to use the exact same perl for installing Inline::Perl5 and Inline::Perl6.
None by default.
http://github.com/niner/Inline-Perl5 for more documentation.
http://github.com/niner/Inline-Perl6 for the latest version.
Stefan Seifert, <nine@detonation.org>
Copyright (C) 2015 by Stefan Seifert
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.20.1 or, at your option, any later version of Perl 5 you may have available.
To install Inline::Perl6, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Inline::Perl6
CPAN shell
perl -MCPAN -e shell install Inline::Perl6
For more information on module installation, please visit the detailed CPAN module installation guide.