andygrove commented on code in PR #1799:
URL: https://github.com/apache/datafusion-comet/pull/1799#discussion_r2109498280
##########
spark/src/main/scala/org/apache/comet/rules/CometScanRule.scala:
##########
@@ -118,7 +119,18 @@ case class CometScanRule(session: SparkSession) extends
Rule[SparkPlan] {
return withInfos(scanExec, fallbackReasons.toSet)
}
- val typeChecker = new CometScanTypeChecker(scanImpl)
+ val possibleDefaultValues =
getExistenceDefaultValues(scanExec.requiredSchema)
+ if (possibleDefaultValues.exists(_ != null && !isInstanceOf[Literal]))
{
Review Comment:
I'm not 100% sure this code is correct because `isInstanceOf` doesn't appear
to be called on `_`? Perhaps we could make this more explicit:
```suggestion
if (possibleDefaultValues.exists(d != null &&
!d.isInstanceOf[Literal])) {
```
--
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]