[pypy-commit] pypy default: merge heads
arigo
pypy.commits at gmail.com
Thu Nov 10 03:46:50 EST 2016
Author: Armin Rigo <arigo at tunes.org>
Branch:
Changeset: r88286:0b074a6a6472
Date: 2016-11-10 09:46 +0100
http://bitbucket.org/pypy/pypy/changeset/0b074a6a6472/
Log: merge heads
diff --git a/rpython/rlib/rarithmetic.py b/rpython/rlib/rarithmetic.py
--- a/rpython/rlib/rarithmetic.py
+++ b/rpython/rlib/rarithmetic.py
@@ -340,7 +340,10 @@
def __mul__(self, other):
x = long(self)
y = other # may be a float
- return self._widen(other, x * y)
+ z = x * y
+ if isinstance(z, (int, long)):
+ z = self._widen(other, z)
+ return z
__rmul__ = __mul__
def __div__(self, other):
More information about the pypy-commit
mailing list