cloud-fan commented on code in PR #37439:
URL: https://github.com/apache/spark/pull/37439#discussion_r953397903


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/UnwrapCastInBinaryComparison.scala:
##########
@@ -156,29 +157,36 @@ object UnwrapCastInBinaryComparison extends 
Rule[LogicalPlan] {
         case lit @ Literal(null, _) => nullList += lit
         case lit @ NonNullLiteral(_, _) =>
           unwrapCast(EqualTo(in.value, lit)) match {

Review Comment:
   now I start to think that creating `EqualTo` and reusing `unwrapCast` may 
not be a good idea here. Is it possible to pull the code of downcasting a value 
to a new function, and call that function here?



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