Lines Matching refs:places

290 	size_t i, places, idx = bc_num_nonZeroLen(n) - 1;  in bc_num_negPow10()  local
292 places = 1; in bc_num_negPow10()
297 if (bc_num_pow10[i] > (BcBigDig) n->num[idx]) places += 1; in bc_num_negPow10()
303 return places + (BC_NUM_RDX_VAL(n) - (idx + 1)) * BC_BASE_DIGS; in bc_num_negPow10()
578 bc_num_truncate(BcNum* restrict n, size_t places) in bc_num_truncate() argument
582 if (!places) return; in bc_num_truncate()
587 places_rdx = nrdx ? nrdx - BC_NUM_RDX(n->scale - places) : 0; in bc_num_truncate()
590 assert(places <= n->scale && (BC_NUM_ZERO(n) || places_rdx <= n->len)); in bc_num_truncate()
592 n->scale -= places; in bc_num_truncate()
619 bc_num_extend(BcNum* restrict n, size_t places) in bc_num_extend() argument
623 if (!places) return; in bc_num_extend()
628 n->scale += places; in bc_num_extend()
635 places_rdx = BC_NUM_RDX(places + n->scale) - nrdx; in bc_num_extend()
650 n->scale += places; in bc_num_extend()
816 bc_num_shiftLeft(BcNum* restrict n, size_t places) in bc_num_shiftLeft() argument
822 if (!places) return; in bc_num_shiftLeft()
825 if (places > n->scale) in bc_num_shiftLeft()
827 size_t size = bc_vm_growSize(BC_NUM_RDX(places - n->scale), n->len); in bc_num_shiftLeft()
834 if (n->scale >= places) n->scale -= places; in bc_num_shiftLeft()
844 dig = (BcBigDig) (places % BC_BASE_DIGS); in bc_num_shiftLeft()
848 places_rdx = BC_NUM_RDX(places); in bc_num_shiftLeft()
889 if (places > n->scale) in bc_num_shiftLeft()
896 n->scale -= places; in bc_num_shiftLeft()
907 bc_num_shiftRight(BcNum* restrict n, size_t places) in bc_num_shiftRight() argument
913 if (!places) return; in bc_num_shiftRight()
918 n->scale += places; in bc_num_shiftRight()
924 dig = (BcBigDig) (places % BC_BASE_DIGS); in bc_num_shiftRight()
935 places_rdx = BC_NUM_RDX(places); in bc_num_shiftRight()
967 n->scale = scale + places; in bc_num_shiftRight()
2895 size_t places, mod, nrdx = BC_NUM_RDX_VAL(n); in bc_num_printExponent() local
2916 places = bc_num_negPow10(n); in bc_num_printExponent()
2920 mod = places % 3; in bc_num_printExponent()
2923 if (eng && mod != 0) places += 3 - mod; in bc_num_printExponent()
2926 bc_num_shiftLeft(&temp, places); in bc_num_printExponent()
2932 places = bc_num_intDigits(n) - 1; in bc_num_printExponent()
2936 mod = places % 3; in bc_num_printExponent()
2937 if (eng && mod != 0) places -= 3 - (3 - mod); in bc_num_printExponent()
2940 bc_num_shiftRight(&temp, places); in bc_num_printExponent()
2950 if (!places) in bc_num_printExponent()
2961 bc_num_bigdig2num(&exp, (BcBigDig) places); in bc_num_printExponent()