Commits

Brian Kearns  committed c3f5e01

oops ldexp breaks translation, remove for now

  • Participants
  • Parent commits 022ea29

Comments (0)

Files changed (4)

File pypy/module/micronumpy/__init__.py

         ('floor_divide', 'floor_divide'),
         ('logaddexp', 'logaddexp'),
         ('logaddexp2', 'logaddexp2'),
-        ('ldexp', 'ldexp'),
         ('real', 'real'),
         ('imag', 'imag'),
         ('ones_like', 'ones_like'),

File pypy/module/micronumpy/interp_ufuncs.py

                                        "allow_complex": False}),
             ("logaddexp2", "logaddexp2", 2, {"promote_to_float": True,
                                        "allow_complex": False}),
-            ("ldexp", "ldexp", 2, {"int_only": True}),
 
             ("ones_like", "ones_like", 1),
             ("zeros_like", "zeros_like", 1),

File pypy/module/micronumpy/test/test_ufuncs.py

         assert find_uncallable_ufuncs('bool') == set(['sign'])
         assert find_uncallable_ufuncs('float') == set(
                 ['bitwise_and', 'bitwise_not', 'bitwise_or', 'bitwise_xor',
-                 'left_shift', 'right_shift', 'invert', 'ldexp'])
+                 'left_shift', 'right_shift', 'invert'])
         assert find_uncallable_ufuncs('complex') == set(
                 ['bitwise_and', 'bitwise_not', 'bitwise_or', 'bitwise_xor',
                  'arctan2', 'deg2rad', 'degrees', 'rad2deg', 'radians',
-                 'fabs', 'fmod', 'invert', 'ldexp', 'mod',
+                 'fabs', 'fmod', 'invert', 'mod',
                  'logaddexp', 'logaddexp2', 'left_shift', 'right_shift',
                  'copysign', 'signbit', 'ceil', 'floor', 'trunc'])
 
         assert logaddexp2(float('inf'), float('-inf')) == float('inf')
         assert logaddexp2(float('inf'), float('inf')) == float('inf')
 
-    def test_ldexp(self):
-        import numpypy as np
-        a = np.ldexp(2, 3)
-        assert type(a) is np.float64 and a == 16.0
-
     def test_ones_like(self):
         from numpypy import array, ones_like
 

File pypy/module/micronumpy/types.py

         float64 = Float64()
         return float64.rint(float64.box(v))
 
-    @raw_binary_op
-    def ldexp(self, v1, v2):
-        return Float64().box(v1 * 2**v2)
-
 class NonNativePrimitive(Primitive):
     _mixin_ = True