[issue8950] In getargs.c, make 'L' code raise TypeError for float arguments.
STINNER Victor
report at bugs.python.org
Tue Jun 8 23:57:42 CEST 2010
STINNER Victor <victor.stinner at haypocalc.com> added the comment:
> One of the places that the 'L' code *is* used is when parsing
> strange C types (like off_t)
It has unexepected consequences. Example:
>>> x=open("x", "w")
>>> x.seek(0.0)
0.0
>>> x.seek(-0.0)
-0.0
>>> x.seek(0.1)
0.1
>>> x.tell()
0
I think that we should just raise an error in Python 3.2 because I consider this as a bug. It remembers me another bug related to file and float: http://bugs.python.org/issue5080#msg92400
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue8950>
_______________________________________
More information about the Python-bugs-list
mailing list