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


##########
python/pyiceberg/expressions/literals.py:
##########
@@ -491,3 +531,8 @@ def _(self, type_var: FixedType) -> 
Optional[Literal[bytes]]:
             return FixedLiteral(self.value)
         else:
             return None
+
+
+def _transform_literal(func: Callable[[T], T], lit: Literal[T]) -> Literal[T]:
+    """Small helper to unwrap the value from the literal, and wrap it again"""
+    return literal(func(lit.value))

Review Comment:
   Good one, done! 👍🏻 



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