diff options
author | Felix Mulder <felix.mulder@gmail.com> | 2016-09-15 19:20:11 +0200 |
---|---|---|
committer | Felix Mulder <felix.mulder@gmail.com> | 2016-10-10 13:25:33 +0200 |
commit | 1946f94d34a929055c2f0d2dd231c5f5e634c536 (patch) | |
tree | 551615127305ce648af3942b225bdbe63e84c8c8 /src/dotty/tools/dotc/reporting/Reporter.scala | |
parent | c9a8bb8d783d288ae2c165b8eefb3ca47c372c4e (diff) | |
download | dotty-1946f94d34a929055c2f0d2dd231c5f5e634c536.tar.gz dotty-1946f94d34a929055c2f0d2dd231c5f5e634c536.tar.bz2 dotty-1946f94d34a929055c2f0d2dd231c5f5e634c536.zip |
Change layout of ErrorMessages
Diffstat (limited to 'src/dotty/tools/dotc/reporting/Reporter.scala')
-rw-r--r-- | src/dotty/tools/dotc/reporting/Reporter.scala | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/dotty/tools/dotc/reporting/Reporter.scala b/src/dotty/tools/dotc/reporting/Reporter.scala index eb9a10a59..401938859 100644 --- a/src/dotty/tools/dotc/reporting/Reporter.scala +++ b/src/dotty/tools/dotc/reporting/Reporter.scala @@ -13,7 +13,7 @@ import java.lang.System.currentTimeMillis import core.Mode import interfaces.Diagnostic.{ERROR, WARNING, INFO} import dotty.tools.dotc.core.Symbols.Symbol -import ErrorExplanations._ +import ErrorMessages._ object Reporter { class Error(msgFn: => String, pos: SourcePosition) extends Diagnostic(msgFn, pos, ERROR) @@ -96,10 +96,10 @@ trait Reporting { this: Context => def warning(msg: => String, pos: SourcePosition = NoSourcePosition): Unit = reporter.report(new Warning(msg, pos)) - def explainWarning(expl: => Explanation, pos: SourcePosition = NoSourcePosition): Unit = { - warning(expl.msg, pos) - if (this.shouldExplain(expl)) - reporter.report(new Info(expl.explanation, NoSourcePosition)) + def explainWarning(err: => ErrorMessage, pos: SourcePosition = NoSourcePosition): Unit = { + warning(err.msg, pos) + if (this.shouldExplain(err)) + reporter.report(new Info(err.explanation, NoSourcePosition)) } def strictWarning(msg: => String, pos: SourcePosition = NoSourcePosition): Unit = @@ -111,10 +111,10 @@ trait Reporting { this: Context => reporter.report(new Error(msg, pos)) } - def explainError(expl: => Explanation, pos: SourcePosition = NoSourcePosition): Unit = { - error(expl.msg, pos) - if (this.shouldExplain(expl)) - reporter.report(new Info(expl.explanation, NoSourcePosition)) + def explainError(err: => ErrorMessage, pos: SourcePosition = NoSourcePosition): Unit = { + error(err.msg, pos) + if (this.shouldExplain(err)) + reporter.report(new Info(err.explanation, NoSourcePosition)) } def errorOrMigrationWarning(msg: => String, pos: SourcePosition = NoSourcePosition): Unit = |