Author: Timo Paulssen <timona...@perpetuum-immobile.de>
Branch: separate-applevel-numpy
Changeset: r47811:436d920d8853
Date: 2011-10-04 00:04 +0200
http://bitbucket.org/pypy/pypy/changeset/436d920d8853/

Log:    inf went missing from numpy somewhere along the way

diff --git a/lib_pypy/numpy/__init__.py b/lib_pypy/numpy/__init__.py
--- a/lib_pypy/numpy/__init__.py
+++ b/lib_pypy/numpy/__init__.py
@@ -37,6 +37,8 @@
         tan,
     )
 
+inf = float("inf")
+
 def average(a):
     # This implements a weighted average, for now we don't implement the
     # weighting, just the average part!
diff --git a/pypy/module/_numpy/test/test_ufuncs.py 
b/pypy/module/_numpy/test/test_ufuncs.py
--- a/pypy/module/_numpy/test/test_ufuncs.py
+++ b/pypy/module/_numpy/test/test_ufuncs.py
@@ -300,7 +300,8 @@
 
     def test_arcsinh(self):
         import math
-        from _numpy import arcsinh, inf
+        from _numpy import arcsinh
+        from numpy import inf
 
         for v in [inf, -inf, 1.0, math.e]:
             assert math.asinh(v) == arcsinh(v)
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to