[Python-Dev] Re: pirate (python+parrot)

Michal Wallace michal at sabren.com
Mon Aug 4 15:37:54 EDT 2003


On Mon, 4 Aug 2003, Dan Sugalski wrote:

> >If your efforts save Dan Sugalski time in implementing Python on
> >Parrot, realize that it may cost me a round of drinks and a laundry
> >run (if Dan has a good aim).

> Nah, this isn't something to worry about, since I can't use it by the 
> terms of the challenge--I have to use the bytecode, not the source. 

Okay, that's just silly. :)

What do you guys think about changing the bet
to allow using the source?

In any case, there's a loophole in the 
"massage the bytecode as needed" clause,
assuming decompyle works with 2.3 :)

  http://www.crazy-compilers.com/decompyle/

By the way, what are the chances of type 
declarations being in python a year from now? 
I thought there was a PEP for this, but I
couldn't find it. :)

There's talk of pirate becoming a generic
code generator for parrot, and I plan to 
support type declarations in the backend. 

I don't really want to change the python
syntax, so I was thinking up an evil
kludge so that people could declare 
types and still use the code in cpython
or jython.

def f(x, y, *etc):
    if compile is open:
        arg.x is int
        arg.y is str
        var.z is int
        return int
    z = 5 
    # ...
    return z

I guess that wraps up the "nuts or brilliant"
question, at least for me... :)

Sincerely,
 
Michal J Wallace
Sabren Enterprises, Inc.
-------------------------------------
contact: michal at sabren.com
hosting: http://www.cornerhost.com/
my site: http://www.withoutane.com/
--------------------------------------




More information about the Python-Dev mailing list