Automatically add -release flag to correctly compile Scala code
tgodzik opened this issue · 4 comments
Currently if we use a newer version of Java for Bloop and try to compile with an older JDK we will get proper bytecode generated for Java files as they fork the compilation, however the same will not happen for Scala code.
For that to work we should automatically add --release
flag similar to how ScalaCLI does it for all bloop plugins:
- maven
- Gradle
- sbt
- mill
This also allow us to only run Bloop on JDK 17 and use the improved support from scala-cli/bloop-core (or even migrate to it)
For that to work we should automatically add --release flag similar to how ScalaCLI does it for all bloop plugins:
Do you have a link handy to show where/how scala-cli does it?
For that to work we should automatically add --release flag similar to how ScalaCLI does it for all bloop plugins:
Do you have a link handy to show where/how scala-cli does it?
That is a good question, I can't find it quickly so I asked the team 😓