summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/Global.scala
diff options
context:
space:
mode:
authorPaul Phillips <paulp@improving.org>2012-04-17 17:13:53 +0100
committerPaul Phillips <paulp@improving.org>2012-04-17 17:15:58 +0100
commitadd30e2f48f0120728a931377cc8a00748f5c9b9 (patch)
tree878bdc7ddefdae5793732aff3a927dbc5026211c /src/compiler/scala/tools/nsc/Global.scala
parente224518c92e3fc8d779848ad82ba1997dd10914e (diff)
downloadscala-add30e2f48f0120728a931377cc8a00748f5c9b9.tar.gz
scala-add30e2f48f0120728a931377cc8a00748f5c9b9.tar.bz2
scala-add30e2f48f0120728a931377cc8a00748f5c9b9.zip
Try to fix sbt.
It depended on the signature of uncheckedWarnings.
Diffstat (limited to 'src/compiler/scala/tools/nsc/Global.scala')
-rw-r--r--src/compiler/scala/tools/nsc/Global.scala9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/Global.scala b/src/compiler/scala/tools/nsc/Global.scala
index bbeee3220b..73c68f44d4 100644
--- a/src/compiler/scala/tools/nsc/Global.scala
+++ b/src/compiler/scala/tools/nsc/Global.scala
@@ -967,10 +967,15 @@ class Global(var currentSettings: Settings, var reporter: NscReporter) extends S
var currentUnit: CompilationUnit = NoCompilationUnit
val deprecationWarnings = new ConditionalWarning("deprecation", settings.deprecation)
- val uncheckedWarnings = new ConditionalWarning("unchecked", settings.unchecked)
+ // This change broke sbt; I gave it the thrilling name of uncheckedWarnings0 so
+ // as to recover uncheckedWarnings for its ever-fragile compiler interface.
+ val uncheckedWarnings0 = new ConditionalWarning("unchecked", settings.unchecked)
val featureWarnings = new ConditionalWarning("feature", settings.feature)
val inlinerWarnings = new ConditionalWarning("inliner", settings.YinlinerWarnings)
- val allConditionalWarnings = List(deprecationWarnings, uncheckedWarnings, featureWarnings, inlinerWarnings)
+ val allConditionalWarnings = List(deprecationWarnings, uncheckedWarnings0, featureWarnings, inlinerWarnings)
+
+ // for sbt's benefit
+ def uncheckedWarnings: List[(Position, String)] = uncheckedWarnings0.warnings.toList
var reportedFeature = Set[Symbol]()