Skip to content

Commit 385af47

Browse files
committed
Fix scala#1369 Print newline after interpreted commands
1 parent 3649fa8 commit 385af47

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,9 +193,11 @@ class ReplDriver(settings: Array[String],
193193
private def interpret(res: ParseResult)(implicit state: State): State =
194194
res match {
195195
case parsed: Parsed if parsed.trees.nonEmpty =>
196-
compile(parsed)
196+
val newState = compile(parsed)
197197
.withHistory(parsed.sourceCode :: state.history)
198198
.newRun(compiler, rootCtx)
199+
out.println() // Prints newline after commands, also fixes #1369
200+
newState
199201

200202
case SyntaxErrors(src, errs, _) =>
201203
displayErrors(errs)

0 commit comments

Comments
 (0)