ump45nose commented on code in PR #3502:
URL: https://github.com/apache/iceberg-rust/pull/3502#discussion_r4348828141
##########
crates/iceberg/src/expr/visitors/row_group_metrics_evaluator.rs:
##########
@@ -1724,6 +1731,72 @@ mod tests {
Ok(())
}
+ // A NaN with the sign bit set sorts below -Inf under `total_cmp`, so it
+ // exercises the `>` / `>=` side of the NaN check as well.
+ const NAN_BOUNDS: [f32; 2] = [f32::NAN, f32::from_bits(0xffc0_0000)];
+
+ fn eval_nan_bounds_inequality(filter: &Predicate, nan: f32) ->
Result<bool> {
+ let row_group_metadata = create_row_group_metadata(
+ 1,
+ 1,
+ Some(Statistics::float(
+ Some(nan),
Review Comment:
Done in a133ee8. The helper now takes `min` and `max` separately, and
`eval_true_for_nan_lower_bound_finite_upper_bound_less_than` checks `<` and
`<=` with `(NaN, 2.0)` for both NaN signs. It fails without the `is_nan()`
check. (AI-assisted reply.)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]