Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Some pir:: => nqp:: in Perl6::ModuleLoader.

  • Loading branch information...
commit ce914fcb3c3d3ae89b462be5b66983e3800c8faf 1 parent fd5d929
Jonathan Worthington authored March 16, 2013

Showing 1 changed file with 5 additions and 8 deletions. Show diff stats Hide diff stats

  1. 13  src/Perl6/ModuleLoader.pm
13  src/Perl6/ModuleLoader.pm
@@ -12,18 +12,15 @@ class Perl6::ModuleLoader {
12 12
     my %settings_loaded;
13 13
     
14 14
     method ctxsave() {
15  
-        $*MAIN_CTX := Q:PIR {
16  
-            getinterp $P0
17  
-            %r = $P0['context';1]
18  
-        };
  15
+        $*MAIN_CTX := nqp::ctxcaller(nqp::ctx());
19 16
         $*CTXSAVE := 0;
20 17
     }
21 18
     
22 19
     method search_path() {
23 20
         # See if we have an @*INC set up, and if so just use that.
24  
-        my $hll_ns := pir::get_root_global__PS('perl6');
25  
-        if nqp::existskey($hll_ns, 'PROCESS') && nqp::existskey($hll_ns<PROCESS>.WHO, '@INC') {
26  
-            my $INC := ($hll_ns<PROCESS>.WHO)<@INC>;
  21
+        my $PROCESS := nqp::gethllsym('perl6', 'PROCESS');
  22
+        if !nqp::isnull($PROCESS) && nqp::existskey($PROCESS.WHO, '@INC') {
  23
+            my $INC := ($PROCESS.WHO)<@INC>;
27 24
             if nqp::defined($INC) {
28 25
                 my @INC := $INC.FLATTENABLE_LIST();
29 26
                 if +@INC {
@@ -308,4 +305,4 @@ class Perl6::ModuleLoader {
308 305
 
309 306
 # We stash this in the perl6 HLL namespace, just so it's easy to
310 307
 # locate. Note this makes it invisible inside Perl 6 itself.
311  
-pir::set_root_global__vPsP(['perl6'], 'ModuleLoader', Perl6::ModuleLoader);
  308
+nqp::bindhllsym('perl6', 'ModuleLoader', Perl6::ModuleLoader);

0 notes on commit ce914fc

Please sign in to comment.
Something went wrong with that request. Please try again.