Chromium Code Reviews| Index: runtime/lib/integers.dart |
| diff --git a/runtime/lib/integers.dart b/runtime/lib/integers.dart |
| index f465e3bd6bc27a8ccc00482e54e26281ae2ad725..e87dba700b759503669df13e4622ceee8f6541d1 100644 |
| --- a/runtime/lib/integers.dart |
| +++ b/runtime/lib/integers.dart |
| @@ -394,8 +394,8 @@ abstract class _IntegerImplementation { |
| if (x == 0) return y; |
| if (y == 0) return x; |
| if ((x == 1) || (y == 1)) return 1; |
| - if (other is _Bigint) { |
| - return _toBigint().gcd(other); |
| + if (y is _Bigint) { |
| + return x._toBigint().gcd(y); |
|
Lasse Reichstein Nielsen
2016/12/06 09:05:23
If other is -0x8000000000000000 (aka min-mint) the
regis
2016/12/06 17:08:15
Agreed.
|
| } |
| return _binaryGcd(x, y, false); |
| } |