Skip to content

Commit 3188a1e

Browse files
authored
Merge pull request #60 from scalacenter/ticket/58
Don't set the classpath manually if args file is used
2 parents 367811e + 3daa5b0 commit 3188a1e

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

compilation/src/main/scalac/scala/tools/benchmark/BenchmarkDriver.scala

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,17 @@ trait BenchmarkDriver extends BaseBenchmarkDriver {
2323

2424

2525
override protected def processSettingsHook(): Boolean = {
26-
if (source == "scala")
27-
settings.sourcepath.value = Paths.get(s"../corpus/$source/$corpusVersion/library").toAbsolutePath.normalize.toString
28-
else
29-
settings.classpath.value = findScalaJars
26+
if (!source.startsWith("@")) {
27+
// Don't set the classpath manually if it's to be loaded by the `@` processor
28+
if (source == "scala")
29+
settings.sourcepath.value = Paths.get(s"../corpus/$source/$corpusVersion/library").toAbsolutePath.normalize.toString
30+
else settings.classpath.value = findScalaJars
31+
if (depsClasspath != null && depsClasspath.nonEmpty)
32+
settings.processArgumentString(s"-cp $depsClasspath")
33+
}
34+
3035
settings.outdir.value = tempDir.getAbsolutePath
3136
settings.nowarn.value = true
32-
if (depsClasspath != null)
33-
settings.processArgumentString(s"-cp $depsClasspath")
3437
true
3538
}
3639
}

0 commit comments

Comments
 (0)