Home | History | Annotate | Download | only in dist

Lines Matching defs:num2

908   unsigned char *num1, *num2;
936 Remember, zeros on the end of num2 are wasted effort for dividing. */
953 num2 = (unsigned char *) malloc (len2+1);
954 if (num2 == NULL) bc_out_of_memory();
955 memcpy (num2, n2->n_value, len2);
956 *(num2+len2) = 0;
957 n2ptr = num2;
1087 free (num2);
1093 /* Division *and* modulo for numbers. This computes both NUM1 / NUM2 and
1094 NUM1 % NUM2 and puts the results in QUOT and REM, except that if QUOT
1099 bc_divmod (bc_num num1, bc_num num2, bc_num *quot, bc_num *rem, int scale)
1106 if (bc_is_zero (num2)) return -1;
1109 rscale = MAX (num1->n_scale, num2->n_scale+scale);
1113 bc_divide (num1, num2, &temp, scale);
1116 bc_multiply (temp, num2, &temp, rscale);
1130 /* Modulo for numbers. This computes NUM1 % NUM2 and puts the
1134 bc_modulo ( bc_num num1, bc_num num2, bc_num *result, int scale)
1136 return bc_divmod (num1, num2, NULL, result, scale);
1197 /* Raise NUM1 to the NUM2 power. The result is placed in RESULT.
1198 Maximum exponent is LONG_MAX. If a NUM2 is not an integer,
1202 bc_raise (bc_num num1, bc_num num2, bc_num *result, int scale)
1213 if (num2->n_scale != 0)
1215 exponent = bc_num2long (num2);
1216 if (exponent == 0 && (num2->n_len > 1 || num2->n_value[0] != 0))