Re: Writing backwards compatible code - when?

2006-04-24 Thread Laurent Pointal
Scott David Daniels a écrit : > Bob Greschke wrote: >> Is there a list of all of the Python commands and modules that tell >> when (what version) they were added to Python? I was hoping the new >> Essential Reference would have it, but it doesn't. > > Here's a reference that stops at 2.3: > >

Re: Writing backwards compatible code - when?

2006-04-19 Thread Kent Johnson
> Bob Greschke wrote: >> Is there a list of all of the Python commands and modules that tell when >> (what version) they were added to Python? I was hoping the new Essential >> Reference would have it, but it doesn't. The Library Reference page for a module or built-in often documents the vers

Re: Writing backwards compatible code - when?

2006-04-18 Thread John Machin
On 19/04/2006 5:40 AM, Bob Greschke wrote: > Is there a list of all of the Python commands and modules that tell when > (what version) they were added to Python? I was hoping the new Essential > Reference would have it, but it doesn't. > Possibly because it was deemed to be not essential :-)

Re: Writing backwards compatible code - when?

2006-04-18 Thread Dan Sommers
On Tue, 18 Apr 2006 13:40:11 -0600, "Bob Greschke" <[EMAIL PROTECTED]> wrote: > Is there a list of all of the Python commands and modules that tell > when (what version) they were added to Python? I was hoping the new > Essential Reference would have it, but it doesn't. I thought it was more coh

Re: Writing backwards compatible code - when?

2006-04-18 Thread Scott David Daniels
Bob Greschke wrote: > Is there a list of all of the Python commands and modules that tell when > (what version) they were added to Python? I was hoping the new Essential > Reference would have it, but it doesn't. Here's a reference that stops at 2.3: http://rgruet.free.fr/PQR2.3.html --S

Re: Writing backwards compatible code - when?

2006-04-18 Thread Bob Greschke
Is there a list of all of the Python commands and modules that tell when (what version) they were added to Python? I was hoping the new Essential Reference would have it, but it doesn't. Thanks! Bob -- http://mail.python.org/mailman/listinfo/python-list

Re: Writing backwards compatible code

2006-04-16 Thread Dave Brueck
Steven D'Aprano wrote: > I came across an interesting (as in the Chinese curse) problem today. I > had to modify a piece of code using generator expressions written with > Python 2.4 in mind to run under version 2.3, but I wanted the code to > continue to use the generator expression if possible. [

Re: Writing backwards compatible code

2006-04-14 Thread James Stroud
Steven D'Aprano wrote: > I came across an interesting (as in the Chinese curse) problem today. I > had to modify a piece of code using generator expressions written with > Python 2.4 in mind to run under version 2.3, but I wanted the code to > continue to use the generator expression if possible. >

Re: Writing backwards compatible code

2006-04-14 Thread Jack Diederich
On Sat, Apr 15, 2006 at 04:04:44AM +1000, Steven D'Aprano wrote: > I came across an interesting (as in the Chinese curse) problem today. I > had to modify a piece of code using generator expressions written with > Python 2.4 in mind to run under version 2.3, but I wanted the code to > continue to u

Re: Writing backwards compatible code

2006-04-14 Thread Felipe Almeida Lessa
Em Sex, 2006-04-14 às 13:37 -0500, Robert Kern escreveu: > Felipe Almeida Lessa wrote: > > Em Sex, 2006-04-14 às 13:28 -0500, Robert Kern escreveu: > > > >>Steven D'Aprano wrote: > >> > >>>I came across an interesting (as in the Chinese curse) problem today. I > >>>had to modify a piece of code us

Re: Writing backwards compatible code

2006-04-14 Thread Robert Kern
Felipe Almeida Lessa wrote: > Em Sex, 2006-04-14 às 13:28 -0500, Robert Kern escreveu: > >>Steven D'Aprano wrote: >> >>>I came across an interesting (as in the Chinese curse) problem today. I >>>had to modify a piece of code using generator expressions written with >>>Python 2.4 in mind to run und

Re: Writing backwards compatible code

2006-04-14 Thread Paul Rubin
Steven D'Aprano <[EMAIL PROTECTED]> writes: > What techniques do others use? I'd just write the generator with a yield statement. The generator expression does the same thing more concisely, I think. -- http://mail.python.org/mailman/listinfo/python-list

Re: Writing backwards compatible code

2006-04-14 Thread Felipe Almeida Lessa
Em Sex, 2006-04-14 às 13:28 -0500, Robert Kern escreveu: > Steven D'Aprano wrote: > > I came across an interesting (as in the Chinese curse) problem today. I > > had to modify a piece of code using generator expressions written with > > Python 2.4 in mind to run under version 2.3, but I wanted the

Re: Writing backwards compatible code

2006-04-14 Thread Robert Kern
Steven D'Aprano wrote: > I came across an interesting (as in the Chinese curse) problem today. I > had to modify a piece of code using generator expressions written with > Python 2.4 in mind to run under version 2.3, but I wanted the code to > continue to use the generator expression if possible.

Writing backwards compatible code

2006-04-14 Thread Steven D'Aprano
I came across an interesting (as in the Chinese curse) problem today. I had to modify a piece of code using generator expressions written with Python 2.4 in mind to run under version 2.3, but I wanted the code to continue to use the generator expression if possible. My first approach was to use a