Dan Sugalski <[EMAIL PROTECTED]> writes:

> At 11:12 AM +0100 1/2/70, James A Duncan wrote:
>>Morning (BST) all,
>>
>> I've started work on B::Parrot, which is a Perl 5 to Parrot
>> translation engine.  Its very basic at the moment, but I've got it
>> successfully translating things like:
>>
>>my $perliv = 10;
>>my $perlpv = "\n";
>>print $perliv;
>>print $perlpv;
>>
>> into working, assemble-able parrot code.  Before I go any further on
>> this crack-fuelled project is there anything I should be aware of?
>> Are others working on this?  Have I done far too much crack smoking
>> to consider doing something like this now?
>
> I think what you're doing makes perfect sense, and it's a good way to
> go. It should allow for all programs that are essentially static by
> CHECK time to be run on Parrot. (Yes, this leaves out runtime
> requires, do file, and string evals, but that's a reasonably small
> fraction of the programs out there.

Runtime requires are okay so long as the file being required is
already loaded. And it should be possible to treewalk the resulting
optree looking for 'dangerous' constructs so at least there'll be some
warning that the thing won't work.

A couple of issues though. How much of the standard library does
dynamic loading 'cos that's not going to work without some careful
thought. Also, XS based modules are going to break unless someone does
something very clever indeed.

But it's still a fine piece of work.

-- 
Piers

   "It is a truth universally acknowledged that a language in
    possession of a rich syntax must be in need of a rewrite."
         -- Jane Austen?

Reply via email to