From reviews-return-700769-archive-asf-public=cust-asf.ponee.io@spark.apache.org Mon Sep 10 15:54:17 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 2A637180656 for ; Mon, 10 Sep 2018 15:54:16 +0200 (CEST) Received: (qmail 64193 invoked by uid 500); 10 Sep 2018 13:54:16 -0000 Mailing-List: contact reviews-help@spark.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list reviews@spark.apache.org Received: (qmail 63577 invoked by uid 99); 10 Sep 2018 13:54:15 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 10 Sep 2018 13:54:15 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 7DE50DFC7C; Mon, 10 Sep 2018 13:54:15 +0000 (UTC) From: maropu To: reviews@spark.apache.org Reply-To: reviews@spark.apache.org References: In-Reply-To: Subject: [GitHub] spark pull request #22364: [SPARK-25379][SQL] Improve AttributeSet and Colum... Content-Type: text/plain Message-Id: <20180910135415.7DE50DFC7C@git1-us-west.apache.org> Date: Mon, 10 Sep 2018 13:54:15 +0000 (UTC) Github user maropu commented on a diff in the pull request: https://github.com/apache/spark/pull/22364#discussion_r216329962 --- Diff: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/AttributeSet.scala --- @@ -39,10 +41,15 @@ object AttributeSet { /** Constructs a new [[AttributeSet]] given a sequence of [[Expression Expressions]]. */ def apply(baseSet: Iterable[Expression]): AttributeSet = { - new AttributeSet( - baseSet - .flatMap(_.references) - .map(new AttributeEquals(_)).toSet) --- End diff -- The name is ok. We still need to use the mutable set instead of `new AttributeSet(sets.foldLeft(Set.empty[AttributeEquals])(_ ++ _.baseSet))`? --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org For additional commands, e-mail: reviews-help@spark.apache.org