gengliangwang commented on code in PR #37209:
URL: https://github.com/apache/spark/pull/37209#discussion_r927280660
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/decimalExpressions.scala:
##########
@@ -125,11 +126,7 @@ case class CheckOverflow(
queryContext)
override protected def doGenCode(ctx: CodegenContext, ev: ExprCode):
ExprCode = {
- val errorContextCode = if (nullOnOverflow) {
- "\"\""
- } else {
- ctx.addReferenceObj("errCtx", queryContext)
- }
+ val errorContextCode = ctx.addReferenceObj("errCtx", queryContext)
Review Comment:
Will the original code work? It avoids adding a reference object.
--
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]