diff options
author | Som Snytt <som.snytt@gmail.com> | 2016-09-10 15:17:49 -0700 |
---|---|---|
committer | Som Snytt <som.snytt@gmail.com> | 2016-09-10 15:17:49 -0700 |
commit | 94518ce0be2ffdb06d1d3f81279fdc05fa568c0b (patch) | |
tree | 4307f49d1d098ed34460f8e648837cecea19f2c2 /src/compiler/scala/tools/nsc/settings | |
parent | 05016d9035ab9b1c866bd9f12fdd0491f1ea0cbb (diff) | |
download | scala-94518ce0be2ffdb06d1d3f81279fdc05fa568c0b.tar.gz scala-94518ce0be2ffdb06d1d3f81279fdc05fa568c0b.tar.bz2 scala-94518ce0be2ffdb06d1d3f81279fdc05fa568c0b.zip |
No warn when discarding r.f(): r.type
The paradigm is `def add(x: X): Unit = listBuffer += x`.
The value that is discarded is not new information.
Also cleans up the recent tweaks to help messaging.
Adds newlines in case they ask for multiple helps.
Diffstat (limited to 'src/compiler/scala/tools/nsc/settings')
-rw-r--r-- | src/compiler/scala/tools/nsc/settings/ScalaSettings.scala | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/compiler/scala/tools/nsc/settings/ScalaSettings.scala b/src/compiler/scala/tools/nsc/settings/ScalaSettings.scala index e10fa3a114..d81d688267 100644 --- a/src/compiler/scala/tools/nsc/settings/ScalaSettings.scala +++ b/src/compiler/scala/tools/nsc/settings/ScalaSettings.scala @@ -38,11 +38,8 @@ trait ScalaSettings extends AbsScalaSettings /** If any of these settings is enabled, the compiler should print a message and exit. */ def infoSettings = List[Setting](version, help, Xhelp, Yhelp, showPlugins, showPhases, genPhaseGraph) - /** Any -option:help? */ - private def multihelp = allSettings exists { case s => s.isHelping case _ => false } - - /** Is an info setting set? */ - def isInfo = (infoSettings exists (_.isSetByUser)) || multihelp + /** Is an info setting set? Any -option:help? */ + def isInfo = infoSettings.exists(_.isSetByUser) || allSettings.exists(_.isHelping) /** Disable a setting */ def disable(s: Setting) = allSettings -= s |