[Python-Dev] Python 2.5 and ast-branch
Nick Coghlan
ncoghlan at gmail.com
Thu Oct 6 12:06:22 CEST 2005
[Brett]
> To answer Nick's email here, I didn't respond to that initial email
> because it seemed specifically directed at Guido and not me.
Fair enough. I think I was actually misrembering the sequence of events
leading up to 2.4a1, so the question was less appropriate for Guido than I
thought :)
[Guido]
> On 10/5/05, Guido van Rossum <guido at python.org> wrote:
>>Given the total lack of response, I have a different suggestion. Let's
>>*abandon* the AST-branch. We're fooling ourselves believing that we
>>can ever switch to that branch, no matter how theoretically better it
>>is.
[Brett]
> Since the original people who have done the majority of the work
> (Jeremy, Tim, Neal, Nick, logistix, and myself) have fallen so far
> behind this probably is not a bad decision. Obviously I would like to
> see the work pan out, but since I personally just have not found the
> time to shuttle the branch the rest of the way I really am in no
> position to say much in terms of objecting to its demise.
If we kill the branch for now, then anyone that wants to bring up the idea
again can write a PEP first, not only to articulate the benefits of switching
to an AST compiler (Jeremy has a few notes scattered around the web on that
front), but also to propose a solid migration strategy. We tried the "develop
in parallel, switch when done"; it doesn't seem to have worked due to the way
it split developer effort between the branches, and both the HEAD and
ast-branch ended up losing out.
> Maybe I can come up with a new design and get my dissertation out of it. =)
A strategy that may work out better is to develop something independent of the
Python core that can:
1. Produce an ASDL based AST structure from:
- Python source code
- CPython 'AST'
- CPython bytecode
2. Parse an ASDL based AST structure and produce:
- Python source code
- CPython 'AST'
- CPython bytecode
That is, initially develop an enhanced replacement for the compiler package,
rather than aiming directly to replace the actual CPython compiler.
Then the folks who want to do serious bytecode hacking can reverse compile the
bytecode on the fly ;)
Cheers,
Nick.
--
Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
---------------------------------------------------------------
http://boredomandlaziness.blogspot.com
More information about the Python-Dev
mailing list