PEP0238 lament
Chris Gonnerman
chris.gonnerman at newcenturycomputers.net
Mon Jul 23 09:10:21 EDT 2001
----- Original Message -----
From: "Roy Smith" <roy at panix.com>
> Well, heck, in perl, "1"/2 is 0.5 as well. I'm sure there are lots of
> people new to programming who gets confused when they discover that
numbers
> and strings are different too. Perhaps we should add auto-conversion of
> strings to numbers to python as well? :-)
If that were the rule in the first place (pre-1.5.2 at least) we wouldn't
cry about it (much).
> The thing that scares me most about this idea is that it breaks existing
> code. And, the idea that there will be conversion tools, and
auto-warnings
> generated, don't impress me. You still need to touch all the old code.
YES. This is my headache too. All the pro-PEP0238 people out there assume
that we will track version upgrades... but I upgraded several systems
directly
from 1.5.2 to 2.1. There's nothing to stop me from doing that with 2.4, and
then I'll be in a world of hurt.
> What about code that you've shipped to customers already? Are we going to
> demand that they not upgrade their python installation, or that they
> maintain a new version for their own work and an old version to keep our
> stuff going?
Ouch.
> While, I happen to like the way integer division works, I could be
> convinced that auto-promotion from int to float might be a good thing, if
> that's the way the language had been defined in the first place. Too late
> to go back now, however.
Much too late.
Consistent rules which are not *wrong* but only *different* should NOT be
changed this late in the game. I really don't think it takes that long to
teach a newbie about integer division; is saving 5 minutes times the number
of newbies out there really worth the man-hours of fixing the bugs and the
serious loss of face when we screw with a fundamental rule?
More information about the Python-list
mailing list