Skip to content

Commit 9b2446e

Browse files
committed
Fix and reinstate repl/errmsgs
1 parent 0125b46 commit 9b2446e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

compiler/src/dotty/tools/repl/ReplDriver.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package dotty.tools.repl
22

3-
import java.io.{File => JFile, PrintStream, PrintWriter}
3+
import java.io.{BufferedWriter, File => JFile, OutputStreamWriter, PrintStream, PrintWriter}
44
import java.nio.charset.StandardCharsets
55

66
import dotty.tools.dotc.ast.Trees._
@@ -428,7 +428,7 @@ class ReplDriver(settings: Array[String],
428428
/** Like ConsoleReporter, but without file paths or real -Xprompt'ing */
429429
private object ReplConsoleReporter extends ConsoleReporter(
430430
reader = null, // this short-circuits the -Xprompt display from waiting for an input
431-
writer = new PrintWriter(out, /* autoFlush = */ true), // write to out, not Console.err
431+
writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(out, StandardCharsets.UTF_8)), /* autoFlush = */ true), // write to out, not Console.err
432432
) {
433433
override def posFileStr(pos: SourcePosition) = "" // omit file paths
434434
}

0 commit comments

Comments
 (0)