1. Gil Shwartz
  2. pypy

Commits

Stian Andreassen  committed 92f8a46

Make test_decimal (the last test) pass.

  • Participants
  • Parent commits 41a49c1
  • Branches improve-rbigint

Comments (0)

Files changed (1)

File pypy/rlib/rbigint.py

View file
         at most (and usually exactly) k = size_v - size_w digits. """
     k = size_v - size_w
     if k == 0:
-        return NULLRBIGINT, v1
+        # We can't use v1, nor NULLRBIGINT here as some function modify the result.
+        assert _v_rshift(w, v, size_w, d) == 0
+        w._normalize()
+        return rbigint([NULLDIGIT]), w
     
     assert k > 0
     a = rbigint([NULLDIGIT] * k, 1, k)