[pypy-dev] How to organize the py3k branch (was: [pypy-commit] pypy py3k: Remove print statement)

Antonio Cuni anto.cuni at gmail.com
Thu Oct 13 10:55:50 CEST 2011

Hi Amaury, hi all,

On 12/10/11 22:23, amauryfa wrote:
> Author: Amaury Forgeot d'Arc<amauryfa at gmail.com>
> Branch: py3k
> Changeset: r47978:36b998dd9966
> Date: 2011-10-12 01:52 +0200
> http://bitbucket.org/pypy/pypy/changeset/36b998dd9966/
> Log:	Remove print statement

uhm... I thought that the idea was to have support for python 2 and 3 from the 
same codebase, while from your commits it seems that your are actually 
destryoing support for python 2.

I think that there are several possible ways to organize the source code, each 
one with pros and cons.  Maybe we should organize an IRC meeting with the 
interested people to decide which direction to follow?

I.e., a list of possibilities (everyone feels free to add more):

- have a branch where we have *only* python3, and rely on hg merge to get the 
improvements to the translator (which is what you are doing right now, I 
think).  It's easier to write, but then it might be hard to keep in sync with 
the default branch

- support for py2 and py3 in the same branch, with minimal duplication of 
code.  This would mean that e.g. in ast.py you would have tons of "if py2: 
enable_print_stmt()", etc.  Personally, I think that the codebase would become 
too cluttered.

- support for py2 and py3 in the same branch, with some duplication of code; 
e.g., we could copy the existing interpreter/ into interpreter/py3k and modify 
it there.  While we are at it, we should try hard to minimize the code 
duplication, but then it's up to us to decide when it's better to duplicate or 
when it's better to share the code between the twos.

- other?


More information about the pypy-dev mailing list