enable -deprecation for Scala 2.10

Enable -deprecation flag to catch old code being use when we migrate
things.
In this commit I moved error to sys.error.
This commit is contained in:
Eugene Yokota 2014-10-10 15:42:26 -04:00
parent 855dff21be
commit cf4e882ac9
4 changed files with 4 additions and 4 deletions

View File

@ -27,7 +27,7 @@ object Credentials {
def toDirect(c: Credentials): DirectCredentials = c match {
case dc: DirectCredentials => dc
case fc: FileCredentials => loadCredentials(fc.path) match {
case Left(err) => error(err)
case Left(err) => sys.error(err)
case Right(dc) => dc
}
}

View File

@ -155,7 +155,7 @@ object EvictionWarning {
val transitiveEvictions: mutable.ListBuffer[EvictionPair] = mutable.ListBuffer()
def guessCompatible(p: EvictionPair): Boolean =
p.evicteds forall { r =>
options.guessCompatible(r.module, p.winner map { _.module }, module.moduleSettings.ivyScala)
options.guessCompatible((r.module, p.winner map { _.module }, module.moduleSettings.ivyScala))
}
pairs foreach {
case p if isScalaArtifact(module, p.organization, p.name) =>

View File

@ -313,7 +313,7 @@ object IvyActions {
private[this] def checkFilesPresent(artifacts: Seq[(IArtifact, File)]) {
val missing = artifacts filter { case (a, file) => !file.exists }
if (missing.nonEmpty)
error("Missing files for publishing:\n\t" + missing.map(_._2.getAbsolutePath).mkString("\n\t"))
sys.error("Missing files for publishing:\n\t" + missing.map(_._2.getAbsolutePath).mkString("\n\t"))
}
}
final class ResolveException(

View File

@ -220,7 +220,7 @@ object UpdateReport {
private[this] def select0(f: DependencyFilter): Seq[File] =
for (cReport <- report.configurations; mReport <- cReport.modules; (artifact, file) <- mReport.artifacts if f(cReport.configuration, mReport.module, artifact)) yield {
if (file == null) error("Null file: conf=" + cReport.configuration + ", module=" + mReport.module + ", art: " + artifact)
if (file == null) sys.error("Null file: conf=" + cReport.configuration + ", module=" + mReport.module + ", art: " + artifact)
file
}