Test flo:unordered? both ways too.
authorTaylor R Campbell <campbell@mumble.net>
Wed, 28 Nov 2018 05:17:34 +0000 (05:17 +0000)
committerTaylor R Campbell <campbell@mumble.net>
Wed, 28 Nov 2018 05:17:34 +0000 (05:17 +0000)
tests/runtime/test-flonum.scm

index 883f46a1c37b20a2dc0bb04985dc739718d2664c..f4b3df766b13589fc8edd152a64eae0888b33dbe 100644 (file)
@@ -248,7 +248,13 @@ USA.
                                 (or (flo:nan? x) (flo:nan? y)))
                     (assert-eqv (yes-traps (lambda ()
                                              (not (flo:unordered? x y))))
-                                (not (or (flo:nan? x) (flo:nan? y))))))
+                                (not (or (flo:nan? x) (flo:nan? y))))
+                    (if (flo:unordered? x y)
+                        (assert-true (or (flo:nan? x) (flo:nan? y))))
+                    (if (not (flo:unordered? x y))
+                        (begin
+                          (assert-false (flo:nan? x))
+                          (assert-false (flo:nan? y))))))
                 cases))
          cases))
   (define-test 'tetrachotomy