Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add initializer for @*INC and %*CUSTOM_LIB
This takes bare start time of rakudo from 0.210 to 0.175 on my machine
  • Loading branch information
lizmat committed Sep 8, 2014
1 parent d59cf8a commit d05d411
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions src/core/Inc.pm
@@ -1,4 +1,4 @@
{
sub INIT-INC-CUSTOM_LIB($inc) {
my @INC;
my %CUSTOM_LIB;

Expand Down Expand Up @@ -149,7 +149,17 @@
PROCESS::<@INC> := @INC;
PROCESS::<%CUSTOM_LIB> := %CUSTOM_LIB;

nqp::bindhllsym('perl6', 'ModuleLoader', CompUnitRepo);
$inc ?? @INC !! %CUSTOM_LIB;
}

multi sub INITIALIZE('@*INC') {
INIT-INC-CUSTOM_LIB(1);

}
multi sub INITIALIZE('%*CUSTOM_LIB') {
INIT-INC-CUSTOM_LIB(0);
}

nqp::bindhllsym('perl6', 'ModuleLoader', CompUnitRepo);

# vim: ft=perl6 expandtab sw=4

0 comments on commit d05d411

Please sign in to comment.