Skip to content

Commit

Permalink
* ext/bigdecimal/bigdecimal.c: suppressed warnings.
Browse files Browse the repository at this point in the history
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27494 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
  • Loading branch information
nobu committed Apr 26, 2010
1 parent 54592ad commit cce2aa4
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions ext/bigdecimal/bigdecimal.c
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,7 @@ BigDecimal_add(VALUE self, VALUE r)
if(VpIsNaN(b)) return b->obj;
if(VpIsNaN(a)) return a->obj;
mx = GetAddSubPrec(a,b);
if(mx==(-1L)) {
if(mx==(U_LONG)-1L) {
GUARD_OBJ(c,VpCreateRbObject(VpBaseFig() + 1, "0"));
VpAddSub(c, a, b, 1);
} else {
Expand Down Expand Up @@ -682,7 +682,7 @@ BigDecimal_sub(VALUE self, VALUE r)
if(VpIsNaN(a)) return a->obj;

mx = GetAddSubPrec(a,b);
if(mx==(-1L)) {
if(mx==(U_LONG)-1L) {
GUARD_OBJ(c,VpCreateRbObject(VpBaseFig() + 1, "0"));
VpAddSub(c, a, b, -1);
} else {
Expand Down Expand Up @@ -2928,8 +2928,8 @@ VpAddAbs(Real *a, Real *b, Real *c)
a_pos = ap;
b_pos = bp;
c_pos = cp;
if(word_shift==-1L) return 0; /* Overflow */
if(b_pos == -1L) goto Assign_a;
if(word_shift==(U_LONG)-1L) return 0; /* Overflow */
if(b_pos == (U_LONG)-1L) goto Assign_a;

mrv = av + bv; /* Most right val. Used for round. */

Expand Down Expand Up @@ -3021,8 +3021,8 @@ VpSubAbs(Real *a, Real *b, Real *c)
a_pos = ap;
b_pos = bp;
c_pos = cp;
if(word_shift==-1L) return 0; /* Overflow */
if(b_pos == -1L) goto Assign_a;
if(word_shift==(U_LONG)-1L) return 0; /* Overflow */
if(b_pos == (U_LONG)-1L) goto Assign_a;

if(av >= bv) {
mrv = av - bv;
Expand Down Expand Up @@ -3297,7 +3297,7 @@ VpMult(Real *c, Real *a, Real *b)
}
if(Carry) {
ii = ind_c;
while((--ii) >= 0) {
while(ii-- > 0) {
c->frac[ii] += Carry;
if(c->frac[ii] >= BASE) {
Carry = c->frac[ii] / BASE;
Expand Down Expand Up @@ -4044,7 +4044,7 @@ VpCtoV(Real *a, const char *int_chr, U_LONG ni, const char *frac, U_LONG nf, con
/* get integer part */
i = 0;
sign = 1;
if(ni >= 0) {
if(1 /*ni >= 0*/) {
if(int_chr[0] == '-') {
sign = -1;
++i;
Expand Down

0 comments on commit cce2aa4

Please sign in to comment.