-1.0
#*1011111111110000000000000000000000000000000000000000000000000000)
- ;; We should add a procedure that tests for floating-point
- ;; infinity and use it here.
(let ((positive-infinity
(integer-to-double
#*0111111111110000000000000000000000000000000000000000000000000000)))
+ (assert-false (flo:finite? positive-infinity))
(assert-true (flo:positive? positive-infinity)))
(let ((negative-infinity
(integer-to-double
#*1111111111110000000000000000000000000000000000000000000000000000)))
+ (assert-false (flo:finite? negative-infinity))
(assert-true (flo:negative? negative-infinity)))
(assert-true
(test-single -1.0
#*10111111100000000000000000000000)
- ;; We should add a procedure that tests for floating-point
- ;; infinity and use it here.
(let ((positive-infinity
(integer-to-single #*01111111100000000000000000000000)))
- (assert-true (flo:positive? positive-infinity)))
+ (assert-true (flo:positive? positive-infinity))
+ (assert-false (flo:finite? positive-infinity)))
(let ((negative-infinity
(integer-to-single #*11111111100000000000000000000000)))
- (assert-true (flo:negative? negative-infinity)))
+ (assert-true (flo:negative? negative-infinity))
+ (assert-false (flo:finite? negative-infinity)))
(assert-true
(flo:nan?