Some more tests:

"check for negative zero"
self assert: (1 bitShift: 1075) reciprocal asFloatD positive.
self assert: (1 bitShift: 1075) reciprocal negated asFloatD negative.

"check for infinity"
self assert: (1 bitShift: 1024) asFloatD = FloatD infinity.
self assert: (1 bitShift: 1024) negated asFloatD = FloatD negativeInfinity.
self assert: ((1 bitShift: 1075)/3) asFloatD = FloatD infinity.
self assert: ((1 bitShift: 1075)/3) negated asFloatD = FloatD negativeInfinity.

"check for non infinity/nan"
self assert: ((1 bitShift: 1024)/3) asFloatD isFinite.
self assert: ((1 bitShift: 1024)/3) negated asFloatD isFinite.
self assert: (3/(1 bitShift: 1075)) asFloatD isFinite.
self assert: (3/(1 bitShift: 1075)) negated asFloatD isFinite.




_______________________________________________
help-smalltalk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-smalltalk

Reply via email to