-
Notifications
You must be signed in to change notification settings - Fork 21
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
Binary incompatibility across Scala 2.12.2/2.12.1 and 2.12.3 versions #10489
Comments
|
I checked it, building with Scala 2.12.1 without the flag and it didn’t work with project in Scala 2.12.3. However, building I can't see any uses of inline annotation in EDIT: Thanks |
Thanks for checking. I meant to try it back home. I don't know much about it, but I'm pretty sure the optimizer will inline what it can, such as unannotated static finals. Eventually @lrytz will show up to explain it to us. I think you can do that when you control the downstream dependencies, of which scala itself has none. I'll try it out if I'm not travelling for the US Labor Day weekend. They call it Labor Day because it's a long weekend for catching up on work you were supposed to finish last week. |
Thanks. Once again thanks EDIT |
The issue is not caused by a difference in the bytecode of the test project (algebirdTest). 2.12.2 and 2.12.3 produce (almost) the same bytecode for that project. The difference is the run-time classpath: when you switch from 2.12.2 to 2.12.3, the Scala library version on the classpath also changes. In 2.12.2, We have to communicate more clearly that the inliner must not be enabled when building a library that's being distributed and expected to be binary compatible. |
The following simple project: https://github.com/Lazu13/algebirdTest.git shows binary incompatibility across Scala 2.12.3 used in project and Scala 2.12.1 used to compile Algebird 0.13.0 library.
Code from Test.scala compiles but fails in runtime with exception:
Aggregator.minBy
uses
Ordering.by(fn)
from scala.math.Ordering
Please note:
JDK 1.8.0_144
The text was updated successfully, but these errors were encountered: