Searched refs:to_integral (Results 1 – 3 of 3) sorted by relevance
/third_party/python/Lib/test/ |
D | test_decimal.py | 2367 ans = str(Decimal('1.5').to_integral(rounding=None, context=None)) 2370 ans = str(Decimal('1.5').to_integral(rounding=None, context=None)) 2372 ans = str(Decimal('1.5').to_integral(rounding=ROUND_UP, context=None)) 2375 self.assertRaises(InvalidOperation, Decimal('sNaN').to_integral, context=None) 2547 r = d.to_integral(ROUND_DOWN) 2564 r = d.to_integral(ROUND_DOWN) 2707 self.assertEqual(D("9999").to_integral(context=xc), 9999) 4513 self.assertEqual(x.to_integral(), 2) 5086 self.assertEqual(x.to_integral(), 10) 5087 self.assertRaises(TypeError, x.to_integral, '10') [all …]
|
/third_party/python/Doc/library/ |
D | decimal.rst | 869 .. method:: to_integral(rounding=None, context=None) 871 Identical to the :meth:`to_integral_value` method. The ``to_integral`` 2076 ... return d.quantize(Decimal(1)) if d == d.to_integral() else d.normalize()
|
/third_party/python/Lib/ |
D | _pydecimal.py | 2715 to_integral = to_integral_value variable in Decimal 5612 to_integral = to_integral_value variable in Context
|