summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-07-13 06:53:12 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-07-13 06:53:12 +0000
commit0001cf6bdc6d0eb9130bfc162b61c26279339e81 (patch)
tree1a824b5b57e168803a3be7a0d27418a6a498019d
parente31c9896d68106a9bdc872c75c3c28f79a5bb4d6 (diff)
* bignum.c (bary_small_lshift): Use size_t instead of long.
(bary_small_rshift): Ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41940 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--bignum.c6
2 files changed, 8 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 37e1efd4b0b..00444b12a2e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sat Jul 13 15:51:38 2013 Tanaka Akira <akr@fsij.org>
+
+ * bignum.c (bary_small_lshift): Use size_t instead of long.
+ (bary_small_rshift): Ditto.
+
Sat Jul 13 15:33:33 2013 Tanaka Akira <akr@fsij.org>
* bignum.c (bary_small_lshift): Functions moved to remove
diff --git a/bignum.c b/bignum.c
index 8af21cf9485..3b3cca6c711 100644
--- a/bignum.c
+++ b/bignum.c
@@ -441,9 +441,9 @@ maxpow_in_bdigit(int base, int *exp_ret)
}
static BDIGIT
-bary_small_lshift(BDIGIT *zds, BDIGIT *xds, long n, int shift)
+bary_small_lshift(BDIGIT *zds, BDIGIT *xds, size_t n, int shift)
{
- long i;
+ size_t i;
BDIGIT_DBL num = 0;
for (i=0; i<n; i++) {
@@ -455,7 +455,7 @@ bary_small_lshift(BDIGIT *zds, BDIGIT *xds, long n, int shift)
}
static void
-bary_small_rshift(BDIGIT *zds, BDIGIT *xds, long n, int shift, int sign_bit)
+bary_small_rshift(BDIGIT *zds, BDIGIT *xds, size_t n, int shift, int sign_bit)
{
BDIGIT_DBL num = 0;
BDIGIT x;