diff options
author | mihaylov <mihaylov@epfl.ch> | 2007-02-06 17:08:03 +0000 |
---|---|---|
committer | mihaylov <mihaylov@epfl.ch> | 2007-02-06 17:08:03 +0000 |
commit | 658bc3c447a78dc1e156036710aa3b0f79ddef1b (patch) | |
tree | 2369ad7579c3e0af2fb7210e2d3ad58c6af7d974 /src/compiler/scala/tools/nsc/CompileServer.scala | |
parent | f1c170f25f647a790126d66cab576d349b16c9b9 (diff) | |
download | scala-658bc3c447a78dc1e156036710aa3b0f79ddef1b.tar.gz scala-658bc3c447a78dc1e156036710aa3b0f79ddef1b.tar.bz2 scala-658bc3c447a78dc1e156036710aa3b0f79ddef1b.zip |
Added a reference to Settings in AbstractReporter
Diffstat (limited to 'src/compiler/scala/tools/nsc/CompileServer.scala')
-rw-r--r-- | src/compiler/scala/tools/nsc/CompileServer.scala | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/compiler/scala/tools/nsc/CompileServer.scala b/src/compiler/scala/tools/nsc/CompileServer.scala index bc99bf321f..24d4b17bd9 100644 --- a/src/compiler/scala/tools/nsc/CompileServer.scala +++ b/src/compiler/scala/tools/nsc/CompileServer.scala @@ -65,6 +65,8 @@ object CompileServer extends SocketServer { private val runtime = Runtime.getRuntime() + var reporter: ConsoleReporter = _ + def session(): unit = { System.out.println("New session" + ", total memory = "+ runtime.totalMemory() + @@ -88,10 +90,6 @@ object CompileServer extends SocketServer { compiler = null return } - val reporter = new ConsoleReporter(in, out) { - // disable prompts, so that compile server cannot block - override def displayPrompt = {} - } def error(msg: String): unit = reporter.error(/*new Position*/ FakePos("fsc"), msg + "\n fsc -help gives more information") @@ -106,7 +104,11 @@ object CompileServer extends SocketServer { new settings.BooleanSetting("-J<flag>", "Pass <flag> directly to runtime system") } - reporter.prompt = command.settings.prompt.value + reporter = new ConsoleReporter(command.settings, in, out) { + // disable prompts, so that compile server cannot block + override def displayPrompt = {} + } + if (command.settings.version.value) reporter.info(null, versionMsg, true) else if (command.settings.help.value) |