equal
deleted
inserted
replaced
1578 ! ! |
1578 ! ! |
1579 |
1579 |
1580 !LimitedPrecisionReal methodsFor:'testing'! |
1580 !LimitedPrecisionReal methodsFor:'testing'! |
1581 |
1581 |
1582 isFinite |
1582 isFinite |
|
1583 "return true, if the receiver is a finite float (not NaN and not +/-INF)" |
|
1584 |
1583 ^ self subclassResponsibility |
1585 ^ self subclassResponsibility |
1584 |
1586 |
1585 "Created: / 7.1.1998 / 12:02:06 / stefan" |
1587 "Created: / 7.1.1998 / 12:02:06 / stefan" |
1586 ! |
1588 ! |
1587 |
1589 |
1594 |
1596 |
1595 "Created: / 14.11.2001 / 14:57:55 / cg" |
1597 "Created: / 14.11.2001 / 14:57:55 / cg" |
1596 ! |
1598 ! |
1597 |
1599 |
1598 isInfinite |
1600 isInfinite |
1599 "return true, if the receiver is an infinite float (Inf). |
1601 "return true, if the receiver is an infinite float (+Inf or -Inf). |
1600 These are not created by ST/X float operations (they raise an exception); |
1602 These are not created by ST/X float operations (they raise an exception); |
1601 however, inline C-code could produce them ..." |
1603 however, inline C-code could produce them." |
1602 |
1604 |
1603 ^ (self isFinite or:[self isNaN]) not. |
1605 ^ (self isFinite or:[self isNaN]) not. |
1604 |
1606 |
1605 " |
1607 " |
1606 1.0 isInfinite |
1608 1.0 isInfinite |
1617 |
1619 |
1618 ^ true |
1620 ^ true |
1619 ! |
1621 ! |
1620 |
1622 |
1621 isNaN |
1623 isNaN |
|
1624 "return true, if the receiver is an invalid float (NaN - not a number). |
|
1625 These are not created by ST/X float operations (they raise an exception); |
|
1626 however, inline C-code could produce them." |
|
1627 |
1622 ^ self subclassResponsibility |
1628 ^ self subclassResponsibility |
1623 |
1629 |
1624 "Modified: 12.2.1997 / 16:45:27 / cg" |
1630 "Modified: 12.2.1997 / 16:45:27 / cg" |
1625 ! |
1631 ! |
1626 |
1632 |