diff options
author | Som Snytt <som.snytt@gmail.com> | 2013-03-26 02:13:13 -0700 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2013-03-27 10:39:22 -0700 |
commit | 22944e474e038f11ac110661eb7e5edbea5d6d13 (patch) | |
tree | 10a50240110d17acbb46f3ba09ff98e2a6465f7d /src/compiler/scala/tools/util/PathResolver.scala | |
parent | e073975997a5291cbe76ea15e797a6783bb4d544 (diff) | |
download | scala-22944e474e038f11ac110661eb7e5edbea5d6d13.tar.gz scala-22944e474e038f11ac110661eb7e5edbea5d6d13.tar.bz2 scala-22944e474e038f11ac110661eb7e5edbea5d6d13.zip |
SI-7261 Implicit conversion of BooleanSetting to Boolean and BooleanFlag
This commit shortens expressions of the form `if (settings.debug.value)` to
`if (settings.debug)` for various settings. Rarely, the setting is supplied
as a method argument. The conversion is not employed in simple definitions
where the Boolean type would have to be specified.
Diffstat (limited to 'src/compiler/scala/tools/util/PathResolver.scala')
-rw-r--r-- | src/compiler/scala/tools/util/PathResolver.scala | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/util/PathResolver.scala b/src/compiler/scala/tools/util/PathResolver.scala index d8e545e6b1..8d65c40a01 100644 --- a/src/compiler/scala/tools/util/PathResolver.scala +++ b/src/compiler/scala/tools/util/PathResolver.scala @@ -146,7 +146,7 @@ object PathResolver { import PathResolver.{ Defaults, Environment, ppcp } class PathResolver(settings: Settings, context: JavaContext) { - def this(settings: Settings) = this(settings, if (settings.inline.value) new JavaContext else DefaultJavaContext) + def this(settings: Settings) = this(settings, if (settings.inline) new JavaContext else DefaultJavaContext) private def cmdLineOrElse(name: String, alt: String) = { (commandLineFor(name) match { @@ -240,7 +240,7 @@ class PathResolver(settings: Settings, context: JavaContext) { lazy val result = { val cp = new JavaClassPath(containers.toIndexedSeq, context) - if (settings.Ylogcp.value) { + if (settings.Ylogcp) { Console.println("Classpath built from " + settings.toConciseString) Console.println("Defaults: " + PathResolver.Defaults) Console.println("Calculated: " + Calculated) |