diff --git a/tests/internal/test_nan_comparison.odin b/tests/internal/test_nan_comparison.odin index 5740be477..b47cc9dfc 100644 --- a/tests/internal/test_nan_comparison.odin +++ b/tests/internal/test_nan_comparison.odin @@ -89,3 +89,100 @@ compare_variable_nans_f64 :: proc(t: ^testing.T) { testing.expect_value(t, NaN > NaN, false) testing.expect_value(t, NaN >= NaN, false) } + +// A complex or quaternion compares componentwise, so a NaN in any one lane makes the whole +// comparison fail. The folded form used to disagree: `cmp_f64` is `(a>b)-(a