aboutsummaryrefslogtreecommitdiff
path: root/sql/core/src/main/scala/org/apache
diff options
context:
space:
mode:
authorhyukjinkwon <gurwls223@gmail.com>2016-04-18 13:45:03 -0700
committerReynold Xin <rxin@databricks.com>2016-04-18 13:45:03 -0700
commit6fc1e72d9b70615bd91b598084406eb1893d6706 (patch)
treeecf9380e635d2adb05b810fbdb5a5b3cf6429f06 /sql/core/src/main/scala/org/apache
parent8c62edb70fdeedf0ca5a7fc154698aea96184cc6 (diff)
downloadspark-6fc1e72d9b70615bd91b598084406eb1893d6706.tar.gz
spark-6fc1e72d9b70615bd91b598084406eb1893d6706.tar.bz2
spark-6fc1e72d9b70615bd91b598084406eb1893d6706.zip
[MINOR] Revert removing explicit typing (changed in some examples and StatFunctions)
## What changes were proposed in this pull request? This PR reverts some changes in https://github.com/apache/spark/pull/12413. (please see the discussion in that PR). from ```scala words.foreachRDD { (rdd, time) => ... ``` to ```scala words.foreachRDD { (rdd: RDD[String], time: Time) => ... ``` Also, this was discussed in dev-mailing list, [here](http://apache-spark-developers-list.1001551.n3.nabble.com/Question-about-Scala-style-explicit-typing-within-transformation-functions-and-anonymous-val-td17173.html) ## How was this patch tested? This was tested with `sbt scalastyle`. Author: hyukjinkwon <gurwls223@gmail.com> Closes #12452 from HyukjinKwon/revert-explicit-typing.
Diffstat (limited to 'sql/core/src/main/scala/org/apache')
-rw-r--r--sql/core/src/main/scala/org/apache/spark/sql/execution/stat/StatFunctions.scala2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/core/src/main/scala/org/apache/spark/sql/execution/stat/StatFunctions.scala b/sql/core/src/main/scala/org/apache/spark/sql/execution/stat/StatFunctions.scala
index 9afbd0e994..d603f63a08 100644
--- a/sql/core/src/main/scala/org/apache/spark/sql/execution/stat/StatFunctions.scala
+++ b/sql/core/src/main/scala/org/apache/spark/sql/execution/stat/StatFunctions.scala
@@ -431,7 +431,7 @@ private[sql] object StatFunctions extends Logging {
s"exceed 1e4. Currently $columnSize")
val table = counts.groupBy(_.get(0)).map { case (col1Item, rows) =>
val countsRow = new GenericMutableRow(columnSize + 1)
- rows.foreach { row =>
+ rows.foreach { (row: Row) =>
// row.get(0) is column 1
// row.get(1) is column 2
// row.get(2) is the frequency