[Python-Dev] Remove str.find in 3.0?
Terry Reedy
tjreedy at udel.edu
Sat Aug 27 03:07:49 CEST 2005
"Raymond Hettinger" <raymond.hettinger at verizon.net> wrote in message
news:000a01c5aa79$f0414020$a8bb9d8d at oemcomputer...
>> Can str.find be listed in PEP 3000 (under builtins) for removal?
>
> FWIW, here is a sample code transformation (extracted from zipfile.py).
> Judge for yourself whether the index version is better:
I am sure that we both could write similar code that would be smoother if
the math module also had a 'powhalf' function that was the same as sqrt
except for returning -1 instead of raising an error on negative or
non-numerical input.
I'll continue in response to Josiah...
Terry J. Reedy
More information about the Python-Dev
mailing list