[Python-3000-checkins] r61659 - python/branches/py3k/Lib/test/test_winsound.py
Brett Cannon
brett at python.org
Fri Mar 21 09:38:19 CET 2008
On Thu, Mar 20, 2008 at 8:13 PM, Guido van Rossum <guido at python.org> wrote:
> You seem to be missing that the original checkin was into the py3k branch. :)
>
Oops. =) I was a little mentally drained at the sprints, obviously.
-Brett
>
>
> On Thu, Mar 20, 2008 at 8:12 PM, Brett Cannon <brett at python.org> wrote:
> > On Thu, Mar 20, 2008 at 8:04 PM, <skip at pobox.com> wrote:
> > > >>>>> "Brett" == Brett Cannon <brett at python.org> writes:
> > >
> > > Brett> On Wed, Mar 19, 2008 at 8:02 PM, amaury.forgeotdarc
> > >
> > > >> Log:
> > > >> Another 2.6-ism in test file
> > > ...
> > >
> > > >> - for i in xrange(100, 2000, 100):
> > > >> + for i in range(100, 2000, 100):
> > >
> > > Brett> How is this a 2.6ism?
> > >
> > > 3.0 spells it "range". "xrange" is gone:
> > >
> > > $ ./python.exe
> > > Python 3.0a3+ (py3k:61686, Mar 20 2008, 22:00:17)
> > > [GCC 4.0.1 (Apple Computer, Inc. build 5370)] on darwin
> > > Type "help", "copyright", "credits" or "license" for more information.
> > > >>> xrange
> > > Traceback (most recent call last):
> > > File "<stdin>", line 1, in <module>
> > > NameError: name 'xrange' is not defined
> > > >>> range
> > > <type 'range'>
> >
> > Right, but 2to3 will handle the conversion. This will just cause 2to3
> > to turn ``range(100)`` into ``list(range(100))``.
> >
> > -Brett
> >
> >
>
>
> > _______________________________________________
> > Python-3000-checkins mailing list
> > Python-3000-checkins at python.org
> > http://mail.python.org/mailman/listinfo/python-3000-checkins
> >
>
>
>
> --
> --Guido van Rossum (home page: http://www.python.org/~guido/)
>
More information about the Python-3000-checkins
mailing list