On Tue, Jan 02, 2007 at 12:01:54AM -0800, Allison Randal wrote:
> - I ran into one bit of strangeness with the assignment operator on 
> simple strings (it was generating an 'assign' opcode with 3 arguments 
> for the source code "$x = 'test'"). I solved it by setting 'pasttype' to 
> 'assign', but now the generated code is unnecessarily calling the 
> 'clone' opcode (e.g. "clone $P10, $P10"). I'll come back and look at it 
> later.

PAST-pm's handling of assignment is about to be refactored a bit
in order to support Perl 6's binding operator (:=).  Yes, the
generated code sometimes calls a clone when it doesn't need to --
this is going be handled by having PAST-pm keep track of which
PMCs are "temporaries" and thus available for re-use instead of
requiring cloning.

> - The old Punie was loading a library of builtin functions in the 'main' 
> routine of every generated Perl 1 script. I haven't figured out how to 
> do that yet in the new PAST, which means that I can only run Perl 1 
> scripts interpreted. They fail when pre-compiled to .pir files because 
> the builtins aren't loaded.

I'll look into this one a bit.  One of the next items that will be
implemented in perl6 (and may make it into PAST-pm) will be to
support BEGIN/CHECK/INIT/END blocks.

Thanks!

Pm

Reply via email to