Repository: spark Updated Branches: refs/heads/master 08698ee1d -> 4ee2cea2a
[SPARK-11122] [BUILD] [WARN] Add tag to fatal warnings Shows that an error is actually due to a fatal warning. Author: Jakob Odersky <joder...@gmail.com> Closes #9128 from jodersky/fatalwarnings. Project: http://git-wip-us.apache.org/repos/asf/spark/repo Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/4ee2cea2 Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/4ee2cea2 Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/4ee2cea2 Branch: refs/heads/master Commit: 4ee2cea2a43f7d04ab8511d9c029f80c5dadd48e Parents: 08698ee Author: Jakob Odersky <joder...@gmail.com> Authored: Fri Oct 16 17:24:18 2015 +0100 Committer: Sean Owen <so...@cloudera.com> Committed: Fri Oct 16 17:24:18 2015 +0100 ---------------------------------------------------------------------- project/SparkBuild.scala | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/spark/blob/4ee2cea2/project/SparkBuild.scala ---------------------------------------------------------------------- diff --git a/project/SparkBuild.scala b/project/SparkBuild.scala index 8f0f310..766edd9 100644 --- a/project/SparkBuild.scala +++ b/project/SparkBuild.scala @@ -164,7 +164,7 @@ object SparkBuild extends PomBuild { // Code snippet taken from https://issues.scala-lang.org/browse/SI-8410. compile in Compile := { val analysis = (compile in Compile).value - val s = streams.value + val out = streams.value def logProblem(l: (=> String) => Unit, f: File, p: xsbti.Problem) = { l(f.toString + ":" + p.position.line.fold("")(_ + ":") + " " + p.message) @@ -181,7 +181,14 @@ object SparkBuild extends PomBuild { failed = failed + 1 } - logProblem(if (deprecation) s.log.warn else s.log.error, k, p) + val printer: (=> String) => Unit = s => if (deprecation) { + out.log.warn(s) + } else { + out.log.error("[warn] " + s) + } + + logProblem(printer, k, p) + } } --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org For additional commands, e-mail: commits-h...@spark.apache.org