From 6871bccae321a04bea28144945c6afa4b6276905 Mon Sep 17 00:00:00 2001 From: Jason Zaugg Date: Wed, 27 Apr 2016 10:45:49 +1000 Subject: SI-9762 Remove workaround after upstream fix in jline Now that we use a release of JLine that includes the fix for: https://github.com/jline/jline2/issues/208 We no longer need to the workaround introduced in 7719a3c. Screencast of the still-fixed behaviour: http://recordit.co/5pzh9OhlQv.gif --- .../tools/nsc/interpreter/jline/JLineReader.scala | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/src/repl-jline/scala/tools/nsc/interpreter/jline/JLineReader.scala b/src/repl-jline/scala/tools/nsc/interpreter/jline/JLineReader.scala index 85287b83f0..95964e18d9 100644 --- a/src/repl-jline/scala/tools/nsc/interpreter/jline/JLineReader.scala +++ b/src/repl-jline/scala/tools/nsc/interpreter/jline/JLineReader.scala @@ -141,26 +141,6 @@ private class JLineConsoleReader extends jconsole.ConsoleReader with interpreter case _ => this addCompleter completer } - // This is a workaround for https://github.com/jline/jline2/issues/208 - // and should not be necessary once we upgrade to JLine 2.13.1 - /// - // Test by: - // scala> {" ".char} - // - // And checking we don't get an extra } on the line. - /// - val handler = getCompletionHandler - setCompletionHandler(new CompletionHandler { - override def complete(consoleReader: ConsoleReader, list: JList[CharSequence], i: Int): Boolean = { - try { - handler.complete(consoleReader, list, i) - } finally if (getCursorBuffer.cursor != getCursorBuffer.length()) { - print(" ") - getCursorBuffer.write(' ') - backspace() - } - } - }) setAutoprintThreshold(400) // max completion candidates without warning } } -- cgit v1.2.3