mirror of
https://github.com/python/cpython.git
synced 2025-07-24 03:35:53 +00:00
Merged revisions 59680-59695 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r59686 | guido.van.rossum | 2008-01-04 00:54:04 +0100 (Fri, 04 Jan 2008) | 2 lines Bug #1301: fixed a bad assert in _tkinter. ........ r59687 | raymond.hettinger | 2008-01-04 01:01:15 +0100 (Fri, 04 Jan 2008) | 3 lines Finish-up the struct module optimizations started at the Iceland NFS sprint. ........ r59688 | christian.heimes | 2008-01-04 01:04:52 +0100 (Fri, 04 Jan 2008) | 1 line Fixed #1687: plistlib.py restricts <integer> to Python int when writing ........ r59689 | christian.heimes | 2008-01-04 01:37:34 +0100 (Fri, 04 Jan 2008) | 1 line Bug #1481296: Fixed long(float('nan'))!=0L. ........ r59691 | andrew.kuchling | 2008-01-04 02:15:50 +0100 (Fri, 04 Jan 2008) | 1 line Markup fixes; grammar tweaks ........ r59692 | andrew.kuchling | 2008-01-04 02:16:12 +0100 (Fri, 04 Jan 2008) | 1 line Add items ........ r59694 | christian.heimes | 2008-01-04 02:48:50 +0100 (Fri, 04 Jan 2008) | 1 line Fixed math.copysign() on Windows ........ r59695 | christian.heimes | 2008-01-04 03:03:25 +0100 (Fri, 04 Jan 2008) | 1 line Filled in some XXX comments ........
This commit is contained in:
parent
bccd63c389
commit
a34706f101
9 changed files with 305 additions and 26 deletions
|
@ -254,6 +254,9 @@ PyLong_FromDouble(double dval)
|
|||
"cannot convert float infinity to int");
|
||||
return NULL;
|
||||
}
|
||||
if (Py_IS_NAN(dval)) {
|
||||
return PyLong_FromLong(0L);
|
||||
}
|
||||
if (dval < 0.0) {
|
||||
neg = 1;
|
||||
dval = -dval;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue