diff options
author | Felix Mulder <felix.mulder@gmail.com> | 2016-09-16 22:28:27 +0200 |
---|---|---|
committer | Felix Mulder <felix.mulder@gmail.com> | 2016-10-10 13:25:34 +0200 |
commit | 787a2ceec02fe07fbb9efee673d3abb7cac2969e (patch) | |
tree | e64a077eea45b0298aca88fdfdd459cf9e1a9e83 /test/test/CompilerTest.scala | |
parent | 5c243778279d8b258d7b1d34dd5146dff07eb437 (diff) | |
download | dotty-787a2ceec02fe07fbb9efee673d3abb7cac2969e.tar.gz dotty-787a2ceec02fe07fbb9efee673d3abb7cac2969e.tar.bz2 dotty-787a2ceec02fe07fbb9efee673d3abb7cac2969e.zip |
Add modifiers to highlighting
Diffstat (limited to 'test/test/CompilerTest.scala')
-rw-r--r-- | test/test/CompilerTest.scala | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/test/test/CompilerTest.scala b/test/test/CompilerTest.scala index dea6a30b1..942948f08 100644 --- a/test/test/CompilerTest.scala +++ b/test/test/CompilerTest.scala @@ -5,6 +5,7 @@ import dotty.partest.DPConfig import dotty.tools.dotc.{Main, Bench, Driver} import dotty.tools.dotc.interfaces.Diagnostic.ERROR import dotty.tools.dotc.reporting._ +import diagnostic.Message import dotty.tools.dotc.util.SourcePosition import dotty.tools.dotc.config.CompilerCommand import dotty.tools.io.PlainFile @@ -237,13 +238,13 @@ abstract class CompilerTest { val storeReporter = new Reporter with UniqueMessagePositions with HideNonSensicalMessages { private val consoleReporter = new ConsoleReporter() private val innerStoreReporter = new StoreReporter(consoleReporter) - def doReport(d: Diagnostic)(implicit ctx: Context): Unit = { - if (d.level == ERROR) { + def doReport(m: Message)(implicit ctx: Context): Unit = { + if (m.level == ERROR) { innerStoreReporter.flush() - consoleReporter.doReport(d) + consoleReporter.doReport(m) } - else if (errorCount > 0) consoleReporter.doReport(d) - else innerStoreReporter.doReport(d) + else if (errorCount > 0) consoleReporter.doReport(m) + else innerStoreReporter.doReport(m) } } val reporter = processor.process(allArgs, storeReporter) |