summaryrefslogtreecommitdiff
path: root/src/repl
diff options
context:
space:
mode:
authorSom Snytt <som.snytt@gmail.com>2016-06-04 15:11:26 -0700
committerSom Snytt <som.snytt@gmail.com>2016-06-04 15:11:26 -0700
commitfcf17beee7304928cb97c4902a2e2833091d3a8f (patch)
tree7613eba4f7c325d8aa81b5757dc6dc78c2f1abdd /src/repl
parent90215ce2b9cb99b5dea7c0ef474eea50755c0a40 (diff)
downloadscala-fcf17beee7304928cb97c4902a2e2833091d3a8f.tar.gz
scala-fcf17beee7304928cb97c4902a2e2833091d3a8f.tar.bz2
scala-fcf17beee7304928cb97c4902a2e2833091d3a8f.zip
SI-7898 Preserve reader against subversion
SBT tries to install its own SimpleReader (for some reason) if it needs to create its own IMain. Because Rube Goldberg needs to execute some postinit hooks, don't let SBT do that.
Diffstat (limited to 'src/repl')
-rw-r--r--src/repl/scala/tools/nsc/interpreter/ILoop.scala5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/repl/scala/tools/nsc/interpreter/ILoop.scala b/src/repl/scala/tools/nsc/interpreter/ILoop.scala
index 7dab371caf..b086b2181e 100644
--- a/src/repl/scala/tools/nsc/interpreter/ILoop.scala
+++ b/src/repl/scala/tools/nsc/interpreter/ILoop.scala
@@ -966,7 +966,10 @@ class ILoop(in0: Option[BufferedReader], protected val out: JPrintWriter)
// while we go fire up the REPL
try {
- createInterpreter()
+ // don't allow ancient sbt to hijack the reader
+ savingReader {
+ createInterpreter()
+ }
intp.initializeSynchronous()
globalFuture = Future successful true
if (intp.reporter.hasErrors) {