Return True if the operand is infinite; otherwise return False. >>> ExtendedContext.is_infinite(Decimal('2.50')) False >>> ExtendedContext.is_infinite(Decimal('-Inf')) True >>> ExtendedContext.is_infinite(Decimal('NaN')) False >>> ExtendedCont
(self, a)
| 4500 | return a.is_finite() |
| 4501 | |
| 4502 | def is_infinite(self, a): |
| 4503 | """Return True if the operand is infinite; otherwise return False. |
| 4504 | |
| 4505 | >>> ExtendedContext.is_infinite(Decimal('2.50')) |
| 4506 | False |
| 4507 | >>> ExtendedContext.is_infinite(Decimal('-Inf')) |
| 4508 | True |
| 4509 | >>> ExtendedContext.is_infinite(Decimal('NaN')) |
| 4510 | False |
| 4511 | >>> ExtendedContext.is_infinite(1) |
| 4512 | False |
| 4513 | """ |
| 4514 | a = _convert_other(a, raiseit=True) |
| 4515 | return a.is_infinite() |
| 4516 | |
| 4517 | def is_nan(self, a): |
| 4518 | """Return True if the operand is a qNaN or sNaN; |