nastra commented on code in PR #11601:
URL: https://github.com/apache/iceberg/pull/11601#discussion_r1850541353


##########
api/src/main/java/org/apache/iceberg/expressions/ExpressionUtil.java:
##########
@@ -337,9 +337,9 @@ public <T> Expression predicate(UnboundPredicate<T> pred) {
               pred.op(), pred.term(), (T) sanitize(pred.literal(), now, 
today));
         case IN:
         case NOT_IN:
-          Iterable<String> iter =
-              () -> pred.literals().stream().map(lit -> sanitize(lit, now, 
today)).iterator();
-          return new UnboundPredicate<>(pred.op(), pred.term(), (Iterable<T>) 
iter);
+          Iterable<T> iter =
+              () -> pred.literals().stream().map(lit -> (T) sanitize(lit, now, 
today)).iterator();

Review Comment:
   L337 also casts the result of `sanitize()` to `T`



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