| CODENOTIFIER | HelpYou are not signed inSign in |
Project: Rakudo
Revision: 30764
Author: pmichaud
Date: 04 Sep 2008 14:53:31
Changes:[rakudo]: code generated by --target=pir now runs from parrot (RT #53040)
Files:| ... | ...@@ -26,9 +26,20 @@ | |
| 26 | 26 | $?INIT := PAST::Block.new(); # For the next eval. |
| 27 | 27 | } |
| 28 | 28 | |
| 29 | # Make sure we have the interpinfo constants. | |
| 29 | # Make sure we have the interpinfo constants. | |
| 30 | 30 | $past.unshift( PAST::Op.new( :inline('.include "interpinfo.pasm"') ) ); |
| 31 | 31 | |
| 32 | # Add code to load perl6.pbc if it's not already present | |
| 33 | my $loadinit := $past.loadinit(); | |
| 34 | $loadinit.unshift( | |
| 35 | PAST::Op.new( :inline('$P0 = compreg "Perl6"', | |
| 36 | 'unless null $P0 goto have_perl6', | |
| 37 | 'load_bytecode "perl6.pbc"', | |
| 38 | 'have_perl6:') | |
| 39 | ) | |
| 40 | ); | |
| 41 | ||
| 42 | ||
| 32 | 43 | # convert the last operation of the block into a .return op |
| 33 | 44 | # so that :load block below isn't used as return value |
| 34 | 45 | $past.push( PAST::Op.new( $past.pop(), :pirop('return') ) ); |