From 6d47a31798227d3b78af2ab048f57b7219d3c416 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Tue, 17 Sep 2013 23:13:29 -0700 Subject: Silence pos/t3960's -Ycheck output. Someday someone will have to straighten out where output goes. Clearly under current conditions, Console.err is not a good place. I rerouted through unit.warning so the output will be swallowed like all the other warnings. --- src/compiler/scala/tools/nsc/typechecker/TreeCheckers.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/compiler') diff --git a/src/compiler/scala/tools/nsc/typechecker/TreeCheckers.scala b/src/compiler/scala/tools/nsc/typechecker/TreeCheckers.scala index 3a188c0044..e44c83aa56 100644 --- a/src/compiler/scala/tools/nsc/typechecker/TreeCheckers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/TreeCheckers.scala @@ -171,8 +171,8 @@ abstract class TreeCheckers extends Analyzer { ) - def errorFn(msg: Any): Unit = Console.err println "[check: %s] %s".format(phase.prev, msg) - def errorFn(pos: Position, msg: Any): Unit = errorFn(posstr(pos) + ": " + msg) + def errorFn(pos: Position, msg: Any): Unit = currentUnit.warning(pos, "[check: %s] %s".format(phase.prev, msg)) + def errorFn(msg: Any): Unit = errorFn(NoPosition, msg) def informFn(msg: Any) { if (settings.verbose || settings.debug) -- cgit v1.2.3