zinc
zinc copied to clipboard
ZincCompilerUtil#scalaCompiler doesn't accept ModuleID
There's a setting called scalaCompilerBridgeSource that lets the end user pick the compiler bridge source module. This is a key escape hatch that allows alternative Scala compiler such as Dotty and Typelevel Scala.
problem
ZincCompilerUtil#scalaCompilerdoes not acceptModuleID.
public static ScalaCompiler scalaCompiler(ScalaInstance scalaInstance,
File compilerBridgeJar,
ClasspathOptions classpathOptions) {
expectation
An alternative entry point with a parameter for compilerBridgeSource: ModuleID and a configuration for Ivy (because the build user's Ivy could be hind firewall etc).
/cc @jvican
Given the lack of librarymanagement API, the next best thing would be to provide interfaceProvider alternative that lets you specify the compilerBridgeSource.
What's the plan you have in mind here?
The only clean solution to fix this issue is to make ModuleID part of the public API, to be honest.
@eed3si9n @Duhemm I propose we make ModuleID part of the public API. What do you think?
@jvican It will be! That's part of sbt/librarymanagement#124.
Great, it was not clear to me it would finally be added. Looks great to me. When that is out, I'll update Zinc's public API to use it.