So, as now Pugs generates PMC code that makes mandel.p6 run faster than Perl 5 (http://use.perl.org/~autrijus/journal/23829), I'm pondering this BEGIN{} mess that Pugs had not dealt with.
Consider this program, example.p6:
use v6;
my $var = BEGIN { say "I'm compiling, man"; time() }
say "Compiled at { time() - $var } seconds ago!";
Is this behaviour correct?
% pugscc --parrot example.p6
I'm compiling, man
% sleep 60
% parrot example.pmc
Compiled at 60 seconds ago!
If not, what is?
Thanks,
/Autrijus/
pgpCLYKeSpQki.pgp
Description: PGP signature
