viirya commented on code in PR #55941:
URL: https://github.com/apache/spark/pull/55941#discussion_r3260877201


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/collectionOperations.scala:
##########
@@ -2738,19 +2738,21 @@ case class ElementAt(
   override def nullSafeEval(value: Any, ordinal: Any): Any = 
doElementAt(value, ordinal)
 
   @transient private lazy val doElementAt: (Any, Any) => Any = left.dataType 
match {
+    case _: ArrayType if failOnError =>

Review Comment:
   suggestion: Add a one-line Scala-side comment explaining the two case _: 
ArrayType clauses are split by failOnError.
   
   ```suggestion
       // ArrayType is split into ANSI (failOnError) and non-ANSI branches.
       // Order matters: the guarded case must come first.
       case _: ArrayType if failOnError =>
   ```



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