Aren't Scala 2.8.1 compiler, applications built with it, Sbt 1.7.4/1.7.5RC and Scala 2.7.7 (needed to run Sbt) known to have any problems running with a current alpha of OpenJDK 7?
JDK 8, 11, and 17 are all reasonable choices both for compiling and running Scala code. Since the JVM is normally backwards compatible, it is usually safe to use a newer JVM for running your code than the one it was compiled on, especially if you are not using JVM features designated “experimental” or “unsafe”.
For example, Scala uses type erasure to be compatible with Java. Type erasure also allows Scala to be easily integrated with dynamically typed languages for the JVM. Some Scala features (such as traits) don't directly map to Java, and in those cases you have to use workarounds (more about this in section 11.3).
Note that you do need a JDK for development (that is, to compile you Scala code into Java bytecode).
Since Scala was built for the JVM platform, its source code is designed to be compiled into Java bytecode so that the code generated can run efficiently on the JVM.
There are issues, mostly with swing because they took some formerly non-generic types and gave them type parameters. Scala is not big on this sort of thing.
I ported trunk to a recent version of openjdk here: https://github.com/scala/scala/tree/openjdk
There was one bit I had to disable until I get a compiler fix, which is documented here: https://lampsvn.epfl.ch/trac/scala/ticket/3634
People frequently post benchmark results for Scala using OpenJDK 7 to the mailing list, and backwards compatibility is always a huge, overpowering concern with Java, so I think everything works fine.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With