You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2022/06/20 14:14:31 UTC
[GitHub] [spark] wangyum commented on a diff in pull request #36925: [SPARK-39520][SQL] Override `--` method for `ExpressionSet` in Scala 2.13
wangyum commented on code in PR #36925:
URL: https://github.com/apache/spark/pull/36925#discussion_r901709796
##########
sql/catalyst/src/main/scala-2.13/org/apache/spark/sql/catalyst/expressions/ExpressionSet.scala:
##########
@@ -132,6 +132,12 @@ class ExpressionSet protected(
newSet
}
+ override def --(that: IterableOnce[Expression]): ExpressionSet = {
+ val newSet = clone()
+ that.iterator.foreach(newSet.remove)
+ newSet
+ }
+
Review Comment:
`++` doesn't have this issue?
--
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: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org