Skip to content

Commit

Permalink
[glue/run.pir] add a crafty read-only %*ENV suggested by jnthn++
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Berends committed Feb 28, 2010
1 parent f2975bf commit 40f0e06
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/glue/run.pir
Expand Up @@ -53,7 +53,7 @@ of the compilation unit.
env = root_new ['parrot';'Env']
$S0 = env['PERL6LIB']
$P0 = split ':', $S0
# Now prepend the installed Parrot languages/perl/lib directory
# Now prepend the installed Parrot languages/perl6/lib directory
interp = getinterp
config = interp[.IGLOBALS_CONFIG_HASH]
$S0 = config['libdir']
Expand All @@ -80,6 +80,10 @@ of the compilation unit.
$P2.'!STORE'($P1)
set_hll_global '@INC', $P2

# Turn the env PMC into %*ENV (just read-only so far)
$P2 = '&CREATE_HASH_LOW_LEVEL'(env)
set_hll_global '%ENV', $P2

# INIT time
'!fire_phasers'('INIT')
$P0 = mainline()
Expand Down

0 comments on commit 40f0e06

Please sign in to comment.