diff options
Diffstat (limited to 'src/compiler/scala/tools/nsc/reporters/ConsoleReporter.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/reporters/ConsoleReporter.scala | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/compiler/scala/tools/nsc/reporters/ConsoleReporter.scala b/src/compiler/scala/tools/nsc/reporters/ConsoleReporter.scala index fdb5c72c3d..52c6ddc6ee 100644 --- a/src/compiler/scala/tools/nsc/reporters/ConsoleReporter.scala +++ b/src/compiler/scala/tools/nsc/reporters/ConsoleReporter.scala @@ -9,6 +9,7 @@ package reporters import java.io.{ BufferedReader, IOException, PrintWriter } import scala.reflect.internal.util._ +import StringOps._ /** * This class implements a Reporter that displays messages on a text @@ -40,7 +41,10 @@ class ConsoleReporter(val settings: Settings, reader: BufferedReader, writer: Pr StringOps.countElementsAsString((severity).count, label(severity)) /** Prints the message. */ - def printMessage(msg: String) { writer.print(msg + "\n"); writer.flush() } + def printMessage(msg: String) { + writer print trimAllTrailingSpace(msg) + "\n" + writer.flush() + } /** Prints the message with the given position indication. */ def printMessage(posIn: Position, msg: String) { |