Re: [Python-Dev] Core projects: 3to2

2009-03-19 Thread andrew cooke
Terry Reedy wrote: > Antoine Pitrou wrote: >> Terry Reedy udel.edu> writes: >>> Some of the people who need to support both late 2.x and 3.x would >>> prefer to write 3.x code and backport. The OP of a current python-list >>> thread asked whether there was any way to write something like >>> >>>

Re: [Python-Dev] Core projects: 3to2

2009-03-19 Thread Terry Reedy
Antoine Pitrou wrote: Terry Reedy udel.edu> writes: Some of the people who need to support both late 2.x and 3.x would prefer to write 3.x code and backport. The OP of a current python-list thread asked whether there was any way to write something like @alias('__nonzero__')

Re: [Python-Dev] Core projects: 3to2

2009-03-18 Thread Benjamin Peterson
2009/3/18 Antoine Pitrou : > >> class C() to class C(object) > > __metaclass__ = type Or even better: just inherit from object in 3.0 and 2.x. :) -- Regards, Benjamin ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/li

Re: [Python-Dev] Core projects: 3to2

2009-03-18 Thread Antoine Pitrou
Terry Reedy udel.edu> writes: > > Some of the people who need to support both late 2.x and 3.x would > prefer to write 3.x code and backport. The OP of a current python-list > thread asked whether there was any way to write something like > > @alias('__nonzero__') > def __bool__(s

Re: [Python-Dev] Core projects: 3to2

2009-03-18 Thread Terry Reedy
Antoine Pitrou wrote: Terry Reedy udel.edu> writes: Or the much requested 3to2 using the same tools. I didn't know there was such a request. I thought it was only a PyPy April fool. Some of the people who need to support both late 2.x and 3.x would prefer to write 3.x code and backport. T