mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* bignum.c (rb_cstr_to_inum): fix 64 bit to 32 bit shorten warning
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
4658478ae1
commit
d74bb62dcc
1 changed files with 4 additions and 4 deletions
8
bignum.c
8
bignum.c
|
@ -2107,8 +2107,8 @@ rb_cstr_to_inum(const char *str, int base, int badcheck)
|
|||
vds = uds + num_bdigits;
|
||||
|
||||
powerv = bignew(2, 1);
|
||||
BDIGITS(powerv)[0] = BIGLO(power);
|
||||
BDIGITS(powerv)[1] = BIGDN(power);
|
||||
BDIGITS(powerv)[0] = (BDIGIT)BIGLO(power);
|
||||
BDIGITS(powerv)[1] = (BDIGIT)BIGDN(power);
|
||||
|
||||
i = 0;
|
||||
while (buf < p) {
|
||||
|
@ -2124,8 +2124,8 @@ rb_cstr_to_inum(const char *str, int base, int badcheck)
|
|||
for (j = 0; j < m; j++) {
|
||||
d = d * base + p[j];
|
||||
}
|
||||
uds[i++] = BIGLO(d);
|
||||
uds[i++] = BIGDN(d);
|
||||
uds[i++] = (BDIGIT)BIGLO(d);
|
||||
uds[i++] = (BDIGIT)BIGDN(d);
|
||||
}
|
||||
for (unit = 2; unit < num_bdigits; unit *= 2) {
|
||||
for (i = 0; i < num_bdigits; i += unit*2) {
|
||||
|
|
Loading…
Add table
Reference in a new issue