zhangfengcdt commented on code in PR #3327:
URL: https://github.com/apache/iceberg-rust/pull/3327#discussion_r4185657836


##########
crates/iceberg/src/expr/visitors/expression_evaluator.rs:
##########
@@ -596,6 +596,38 @@ mod tests {
         Ok(())
     }
 
+    #[test]
+    fn test_expr_eq_signed_zero() -> Result<()> {
+        let case_sensitive = true;
+        let (partition_spec, schema) = 
create_partition_spec(PrimitiveType::Float)?;
+
+        let data_file = DataFile {
+            partition: Struct::from_iter([Some(Literal::float(-0.0_f32))]),
+            ..create_data_file_float()
+        };
+
+        // -0.0 and 0.0 are different values, as in iceberg-java's evaluator.
+        for (literal, expected) in [(0.0_f32, false), (-0.0_f32, true)] {

Review Comment:
   Sure! I added test_expr_in_signed_zero: for a -0.0 partition it checks that 
IN (0.0, 1.0) doesn't match, IN (-0.0, 1.0) does, and IN (0.0, -0.0) does.



-- 
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]

Reply via email to