aboutsummaryrefslogtreecommitdiffstats
path: root/bignum.c
diff options
context:
space:
mode:
authorshyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-11-16 03:34:53 +0000
committershyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-11-16 03:34:53 +0000
commit73549c501f9ebb741732b91d0ccdc255e6960a3b (patch)
tree522e11f2a6b79a63ff01faa00d97a8f383ad6953 /bignum.c
parent1a84c57e23d7f30943e60b5f5d1709a98df26ccd (diff)
downloadruby-73549c501f9ebb741732b91d0ccdc255e6960a3b.tar.gz
bignum.c: fix bug in big2dbl()
I was wrong at r65753. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bignum.c')
-rw-r--r--bignum.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/bignum.c b/bignum.c
index 8497ae27ee..b3046f2017 100644
--- a/bignum.c
+++ b/bignum.c
@@ -5283,7 +5283,8 @@ big2dbl(VALUE x)
mask <<= bits;
bit <<= bits;
dl &= mask;
- dl |= bit;
+ dl += bit;
+ dl = BIGLO(dl);
if (!dl) d += 1;
}
}