From fdcda3313da5415b62bff9341081dd266ca76cb3 Mon Sep 17 00:00:00 2001 From: Josh Suereth Date: Tue, 11 Sep 2012 13:44:40 -0400 Subject: Fixes SI-6268. Review by @paulp and @lrytz. This reverts a refactoring from https://github.com/scala/scala/commit/963aabbeb4 MultiString settings would not properly write an unparse string that could be reparsed, leading to failures when forking scalac in ant. Specifically, if a setting was empty, it was getting added to the unparse string and causing scalac to fail. This at least reverts to previous behavior (also more correct for multiple values). Whatever we do here has to work with the @file style argument reading and can't place empty options on the command line. Also, This assumes there are tests around the behvior the REPL needs. Note: The test is not automated yet, so unfortunately, we need to improve ANT testing capabilities to prevent regressons --- src/compiler/scala/tools/nsc/settings/MutableSettings.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/compiler/scala/tools/nsc/settings/MutableSettings.scala') diff --git a/src/compiler/scala/tools/nsc/settings/MutableSettings.scala b/src/compiler/scala/tools/nsc/settings/MutableSettings.scala index 116eed0f31..2ff81ae603 100644 --- a/src/compiler/scala/tools/nsc/settings/MutableSettings.scala +++ b/src/compiler/scala/tools/nsc/settings/MutableSettings.scala @@ -536,7 +536,7 @@ class MutableSettings(val errorFn: String => Unit) } override def tryToSetColon(args: List[String]) = tryToSet(args) override def tryToSetFromPropertyValue(s: String) = tryToSet(s.trim.split(',').toList) - def unparse: List[String] = name :: value + def unparse: List[String] = value map (name + ":" + _) withHelpSyntax(name + ":<" + arg + ">") } -- cgit v1.2.3