diff options
author | Mark Spruiell <mes@zeroc.com> | 2015-12-02 11:28:31 -0800 |
---|---|---|
committer | Mark Spruiell <mes@zeroc.com> | 2015-12-02 11:28:31 -0800 |
commit | 7ea494f049785c1adf0ec7693cae7744276e42d2 (patch) | |
tree | 889a2cdbf371c155a26b6225e2b0c03d58b840ab /python/modules | |
parent | Fix for ICE-6896 - sporadic binding test failure with the Python language map... (diff) | |
download | ice-7ea494f049785c1adf0ec7693cae7744276e42d2.tar.bz2 ice-7ea494f049785c1adf0ec7693cae7744276e42d2.tar.xz ice-7ea494f049785c1adf0ec7693cae7744276e42d2.zip |
Fixes for ICE-6905 - support NaN/Infinity in scripting languages
Diffstat (limited to 'python/modules')
-rw-r--r-- | python/modules/IcePy/Types.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/python/modules/IcePy/Types.cpp b/python/modules/IcePy/Types.cpp index ea749bad672..45579378801 100644 --- a/python/modules/IcePy/Types.cpp +++ b/python/modules/IcePy/Types.cpp @@ -726,7 +726,7 @@ IcePy::PrimitiveInfo::validate(PyObject* p) { // Ensure double does not exceed maximum float value before casting double val = PyFloat_AsDouble(p); - return val <= numeric_limits<float>::max() && val >= -numeric_limits<float>::max(); + return (val <= numeric_limits<float>::max() && val >= -numeric_limits<float>::max()) || !isfinite(val); } break; |