[Python-3000] Fwd: Re: Octal

Thomas Wouters thomas at python.org
Wed Mar 14 21:59:36 CET 2007


On 3/14/07, Steven Bethard <steven.bethard at gmail.com> wrote:
>
> On 3/14/07, Thomas Wouters <thomas at python.org> wrote:
> >
> >
> > On 3/14/07, Raymond Hettinger <python at rcn.com> wrote:
> > > - In 3.0, we don't want an exception.
> >
> > Eh, no, you might not want one, but I most assuredly do want an
> exception.
> > Having formerly-octal literals suddenly give wrong results would be much
> > more of a stumbling block than having them in the first place,
> especially
> > considering we forgot to change all the other languages out there. An
> > exception can make the difference between '0t60' and '60' clear in a
> single
> > message, not to mention refuse the temptation to guess.
>
> Sorry, but could you explain why having the -py3k flag raise the
> exception for your 2.X code wouldn't be sufficient?  Is it because you
> expect your fingers will continue to type 0660 instead of 0t660 when
> you're writing Python 3000 code?


Not just me. The world. This isn't a "re-educate people used to a wart in
Python 2.x" kind of thing. This is a "re-educate new programmers coming from
other languages" kind of thing. The stuff we warn about with -Wpy3k in
Python 2.6 is stuff that is a change in how Python 3.0 does things compared
to 2.x. This isn't just a change compared to 2.6, this is a change compared
to quite a lot of popular programming languages out there.

-- 
Thomas Wouters <thomas at python.org>

Hi! I'm a .signature virus! copy me into your .signature file to help me
spread!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/python-3000/attachments/20070314/471d7af0/attachment.htm 


More information about the Python-3000 mailing list