Skip to content

fix procedure syntax #223

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 14, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions scalac-scoverage-plugin/src/main/scala/scoverage/plugin.scala
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class ScoveragePlugin(val global: Global) extends Plugin {
val instrumentationComponent = new ScoverageInstrumentationComponent(global, extraAfterPhase, extraBeforePhase)
override val components: List[PluginComponent] = List(instrumentationComponent)

override def processOptions(opts: List[String], error: String => Unit) {
override def processOptions(opts: List[String], error: String => Unit): Unit = {
val options = new ScoverageOptions
for (opt <- opts) {
if (opt.startsWith("excludedPackages:")) {
Expand Down Expand Up @@ -227,7 +227,7 @@ class ScoverageInstrumentationComponent(val global: Global, extraAfterPhase: Opt
def isStatementIncluded(pos: Position): Boolean = coverageFilter.isLineIncluded(pos)
def isSymbolIncluded(symbol: Symbol): Boolean = coverageFilter.isSymbolIncluded(symbol.fullNameString)

def updateLocation(t: Tree) {
def updateLocation(t: Tree): Unit = {
Location(global)(t) match {
case Some(loc) => this.location = loc
case _ => reporter.warning(t.pos, s"[warn] Cannot update location for $t")
Expand Down Expand Up @@ -259,7 +259,7 @@ class ScoverageInstrumentationComponent(val global: Global, extraAfterPhase: Opt
)
}

def debug(t: Tree) {
def debug(t: Tree): Unit = {
import scala.reflect.runtime.{universe => u}
reporter.echo(t.getClass.getSimpleName + ": LINE " + safeLine(t) + ": " + u.showRaw(t))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,16 +65,16 @@ class CoberturaXmlWriterTest extends FunSuite with BeforeAndAfter with OneInstan
val builder = domFactory.newDocumentBuilder()
builder.setErrorHandler(new ErrorHandler() {
@Override
def error(e: SAXParseException) {
def error(e: SAXParseException): Unit = {
fail(e)
}
@Override
def fatalError(e: SAXParseException) {
def fatalError(e: SAXParseException): Unit = {
fail(e)
}

@Override
def warning(e: SAXParseException) {
def warning(e: SAXParseException): Unit = {
fail(e)
}
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class LocationCompiler(settings: scala.tools.nsc.Settings, reporter: scala.tools
}
}

override def computeInternalPhases() {
override def computeInternalPhases(): Unit = {
super.computeInternalPhases()
addToPhasesSet(locationSetter, "sets locations")
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ class ScoverageCompiler(settings: scala.tools.nsc.Settings, reporter: scala.tool
}
}

override def computeInternalPhases() {
override def computeInternalPhases(): Unit = {
super.computeInternalPhases()
addToPhasesSet(validator, "scoverage validator")
addToPhasesSet(instrumentationComponent, "scoverage instrumentationComponent")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ trait FileFilter {
}

trait JsFileObject {
def write(path: String, data: String, mode: String = "a")
def write(path: String, data: String, mode: String = "a"): Unit
def pathJoin(path: String, child: String): String
def apply(path: String): JsFile
}