Fokko commented on code in PR #8971:
URL: https://github.com/apache/iceberg/pull/8971#discussion_r1381237282


##########
api/src/main/java/org/apache/iceberg/transforms/Hours.java:
##########
@@ -57,15 +58,16 @@ public boolean satisfiesOrderOf(Transform<?, ?> other) {
     }
 
     if (other instanceof Timestamps) {
-      return other == Timestamps.HOUR;
-    } else if (other instanceof Hours
-        || other instanceof Days
-        || other instanceof Months
-        || other instanceof Years) {
-      return true;
+      return ((Timestamps) other).getResultTypeUnit() == ChronoUnit.HOURS

Review Comment:
   Can we cast once and store it in a local variable?



-- 
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: issues-unsubscr...@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to