summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/GenericRunnerCommand.scala
diff options
context:
space:
mode:
authorSom Snytt <som.snytt@gmail.com>2016-02-25 13:41:20 -0800
committerSom Snytt <som.snytt@gmail.com>2016-05-20 17:01:34 -0700
commit99dad60d984d3f72338f3bad4c4fe905090edd51 (patch)
treec70abab26b1116869e02606abac1167232ab28f4 /src/compiler/scala/tools/nsc/GenericRunnerCommand.scala
parent0d0671ae10ef552d66861248fa087306c960520e (diff)
downloadscala-99dad60d984d3f72338f3bad4c4fe905090edd51.tar.gz
scala-99dad60d984d3f72338f3bad4c4fe905090edd51.tar.bz2
scala-99dad60d984d3f72338f3bad4c4fe905090edd51.zip
SI-7898 Read user input during REPL warmup
The compiler is created on main thread and user input is read on an aux thread (opposite to currently). Fixes completion when `-i` is supplied. Now `-i` means pasted and new option `-I` means line-by-line. The temporary reader uses postInit to swap in the underlying reader. Completion is disabled for the temporary reader, rather than blocking while it waits for a compiler. But manically hitting tab is one way of knowing exactly when completion is live.
Diffstat (limited to 'src/compiler/scala/tools/nsc/GenericRunnerCommand.scala')
-rw-r--r--src/compiler/scala/tools/nsc/GenericRunnerCommand.scala1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/compiler/scala/tools/nsc/GenericRunnerCommand.scala b/src/compiler/scala/tools/nsc/GenericRunnerCommand.scala
index 24496fa013..bab612bad5 100644
--- a/src/compiler/scala/tools/nsc/GenericRunnerCommand.scala
+++ b/src/compiler/scala/tools/nsc/GenericRunnerCommand.scala
@@ -79,6 +79,7 @@ Other startup options:
-howtorun what to run <script|object|jar|guess> (default: guess)
-i <file> preload <file> before starting the repl
+ -I <file> preload <file>, enforcing line-by-line interpretation
-e <string> execute <string> as if entered in the repl
-save save the compiled script in a jar for future use
-nc no compilation daemon: do not use the fsc offline compiler