Vivek1106-04 commented on code in PR #59437:
URL: https://github.com/apache/spark/pull/59437#discussion_r4577411628


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/Expression.scala:
##########
@@ -1429,6 +1429,19 @@ trait CommutativeExpression extends Expression {
       f: PartialFunction[CommutativeExpression, Seq[Expression]]): 
Seq[Expression] =
     gatherCommutative(this, f).sortBy(_.hashCode())
 
+  /**
+   * Reorders only the two direct children of a binary commutative operator, 
without flattening
+   * adjacent operators. Used when the operator is commutative but not 
associative, e.g.
+   * floating-point addition and multiplication.
+   */
+  protected def orderBinaryCommutative(

Review Comment:
   Done in d11a1b8. The `Expression.canonicalized` and `MultiCommutativeOp` 
scaladocs now name resolved FLOAT/DOUBLE `Add` and `Multiply` as the exception 
and point to `orderBinaryCommutative`.



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