Lines Matching refs:_int
221 ans = _dec_from_triple(args[0]._sign, args[0]._int, 'n', True)
509 __slots__ = ('_exp','_int','_sign', '_is_special')
511 # (-1)**_sign * _int * 10**_exp
530 # Note that the coefficient, self._int, is actually stored as
559 self._int = str(int(intpart+fracpart))
566 self._int = str(int(diag or '0')).lstrip('0')
573 self._int = '0'
585 self._int = str(abs(value))
593 self._int = value._int
600 self._int = str(value.int)
619 self._int = '0'
636 self._int = ''.join(map(str, digits))
641 self._int = ''.join(map(str, digits or [0]))
654 self._int = value._int
798 return self._is_special or self._int != '0'
834 self_padded = self._int + '0'*(self._exp - other._exp)
835 other_padded = other._int + '0'*(other._exp - self._exp)
984 self._exp+len(self._int),
985 self._int.rstrip('0')))
992 return DecimalTuple(self._sign, tuple(map(int, self._int)), self._exp)
1010 return sign + 'NaN' + self._int
1012 return sign + 'sNaN' + self._int
1014 # number of digits of self._int to left of decimal point
1015 leftdigits = self._exp + len(self._int)
1017 # dotplace is number of digits of self._int to the left of the
1026 elif self._int == '0':
1035 fracpart = '.' + '0'*(-dotplace) + self._int
1036 elif dotplace >= len(self._int):
1037 intpart = self._int+'0'*(dotplace-len(self._int))
1040 intpart = self._int[:dotplace]
1041 fracpart = '.' + self._int[dotplace:]
1275 if self._int == '1':
1276 ans = _dec_from_triple(resultsign, other._int, resultexp)
1279 if other._int == '1':
1280 ans = _dec_from_triple(resultsign, self._int, resultexp)
1330 shift = len(other._int) - len(self._int) + context.prec + 1
1601 return s*int(self._int)*10**self._exp
1603 return s*int(self._int[:self._exp] or '0')
1630 payload = self._int
1673 exp_min = len(self._int) + self._exp - context.prec
1687 digits = len(self._int) + self._exp - exp_min
1693 coeff = self._int[:digits] or '0'
1726 self_padded = self._int + '0'*(self._exp - Etop)
1734 # prec is an integer satisfying 0 <= prec < len(self._int)
1744 if _all_zeros(self._int, prec):
1755 if self._int[prec] in '56789':
1757 elif _all_zeros(self._int, prec):
1764 if _exact_half(self._int, prec):
1771 if _exact_half(self._int, prec) and \
1772 (prec == 0 or self._int[prec-1] in '02468'):
1793 if prec and self._int[prec-1] not in '05':
1847 str(int(self._int) * int(other._int)),
2315 ans = _dec_from_triple(1, ans._int, ans._exp)
2355 if len(ans._int) <= context.prec:
2356 expdiff = context.prec + 1 - len(ans._int)
2357 ans = _dec_from_triple(ans._sign, ans._int+'0'*expdiff,
2415 end = len(dup._int)
2417 while dup._int[end-1] == '0' and exp < exp_max:
2420 return _dec_from_triple(dup._sign, dup._int[:end], exp)
2476 if len(ans._int) > context.prec:
2527 self._int + '0'*(self._exp - exp), exp)
2531 digits = len(self._int) + self._exp - exp
2537 coeff = self._int[:digits] or '0'
2664 l = (len(self._int) >> 1) + 1
2667 l = len(self._int)+1 >> 1
2794 rest = self._int[self._exp:]
2801 return self._int[-1+self._exp] in '02468'
2806 return self._exp + len(self._int) - 1
2853 self_key = len(self._int), self._int
2854 other_key = len(other._int), other._int
2917 return _dec_from_triple(0, self._int, self._exp, self._is_special)
2922 return _dec_from_triple(0, self._int, self._exp, self._is_special)
2924 return _dec_from_triple(1, self._int, self._exp, self._is_special)
2929 return _dec_from_triple(other._sign, self._int,
3061 return not self._is_special and self._int == '0'
3070 adj = self._exp + len(self._int) - 1
3150 adj = self._exp + len(self._int) - 1
3193 if self._int[0] == '1' and self._int[1:] == '0'*(len(self._int) - 1):
3195 ans = Decimal(self._exp + len(self._int) - 1)
3258 for dig in self._int:
3287 (opa, opb) = self._fill_logical(context, self._int, other._int)
3311 (opa, opb) = self._fill_logical(context, self._int, other._int)
3328 (opa, opb) = self._fill_logical(context, self._int, other._int)
3553 rotdig = self._int
3586 d = _dec_from_triple(self._sign, self._int, self._exp + int(other))
3611 rotdig = self._int
3676 self = _dec_from_triple(self._sign, self._int, self._exp+2)
3686 elif spec['type'] in 'gG' and len(self._int) > precision:
3694 leftdigits = self._exp + len(self._int)
3711 fracpart = '0'*(-dotplace) + self._int
3712 elif dotplace > len(self._int):
3713 intpart = self._int + '0'*(dotplace-len(self._int))
3716 intpart = self._int[:dotplace] or '0'
3717 fracpart = self._int[dotplace:]
3734 self._int = coefficient
3934 if d._isnan() and len(d._int) > self.prec - self._clamp:
5431 self.int = int(value._int)