cloud-fan commented on a change in pull request #32885: URL: https://github.com/apache/spark/pull/32885#discussion_r650141027
########## File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/subquery.scala ########## @@ -76,13 +76,6 @@ abstract class SubqueryExpression( AttributeSet.fromAttributeSets(outerAttrs.map(_.references)) override def children: Seq[Expression] = outerAttrs ++ joinCond override def withNewPlan(plan: LogicalPlan): SubqueryExpression - override def semanticEquals(o: Expression): Boolean = o match { Review comment: all the subclasses of `SubqueryExpression` have implemented `canonicalized`. ########## File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/namedExpressions.scala ########## @@ -278,11 +278,6 @@ case class AttributeReference( case _ => false } - override def semanticEquals(other: Expression): Boolean = other match { - case ar: AttributeReference => sameRef(ar) - case _ => false - } - Review comment: The default implementation works for `AttributeReference` ########## File path: sql/core/src/main/scala/org/apache/spark/sql/execution/subquery.scala ########## @@ -127,11 +126,6 @@ case class InSubqueryExec( override def withNewPlan(plan: BaseSubqueryExec): InSubqueryExec = copy(plan = plan) final override def nodePatternsInternal: Seq[TreePattern] = Seq(IN_SUBQUERY_EXEC) - override def semanticEquals(other: Expression): Boolean = other match { - case in: InSubqueryExec => child.semanticEquals(in.child) && plan.sameResult(in.plan) - case _ => false - } - Review comment: It's already there, in L164 -- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org