Author: Philip Jenvey <[email protected]>
Branch: 
Changeset: r46078:4d824e4fcf57
Date: 2011-07-28 18:32 -0700
http://bitbucket.org/pypy/pypy/changeset/4d824e4fcf57/

Log:    fix handling of inf in jvm's frexp

diff --git a/pypy/translator/jvm/src/pypy/PyPy.java 
b/pypy/translator/jvm/src/pypy/PyPy.java
--- a/pypy/translator/jvm/src/pypy/PyPy.java
+++ b/pypy/translator/jvm/src/pypy/PyPy.java
@@ -1100,9 +1100,9 @@
         if (Double.isNaN(x))
             return interlink.recordFloatSigned(x, 0);
 
-        // Infinity: Python throws exception
+        // Infinity: Python returns (inf, 0)
         if (Double.isInfinite(x))
-            interlink.throwOverflowError();
+            return interlink.recordFloatSigned(x, 0);
 
         // Extract the various parts of the format:
         final long e=11, f=52; // number of bits in IEEE format
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to