-
Notifications
You must be signed in to change notification settings - Fork 449
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
Method references are not taken into account by proguard #142
Comments
The log has some warnings about "AsyncTaskBuilder.java uses unchecked or unsafe operations." Does fixing those help? |
Fixed the warning (replaced varargs generic parameter by generic array parameter), but the issue still exists: https://travis-ci.org/denis-itskovich/retrolambda-method-ref-repro/builds/85513111 One more observation:The issue does not reproduce if I replace method reference by lambda: |
In my case, method references were causing failure even with proguard disabled, with error like:
The reason was incompatibility with gradle-errorprone-plugin. Given that this plug-in play with compiler it's not that a surprise. It used to work with previous version of gradle-retrolambda though. |
Did you try using the latest retrolambda version?
|
Recently tried - getting the same error with 2.0.6 |
I'm getting this same error with 3.3.0-beta4. |
Getting NoClassDefFound error on java.utils.Objects on both latest stable and 3.3.0 beta versions. |
You need to update to the latest retrolamba, see luontola/retrolambda#75 |
Same issue: java.lang.NoClassDefFoundError: java.util.Objects |
You did
correct? |
I'm TRULY sorry... |
Reproducible in an Android project with apply plugin: 'me.tatarka.retrolambda' is put at the last. This plugin was working at past time. |
Ignoring these warnings is enough to fix it:
|
I'm not sure whether it's an issue of
retrolambda
itself orgradle-retrolambda
Background
Proguard seems to shrink methods, referenced as method references. See an example below:
After building, the following error is shown:
Full log is available at travis-ci
Sample android project
Simple android project (with 1 class), reproducing the issue can be found here:
https://github.com/denis-itskovich/retrolambda-method-ref-repro
Related issues
The issue seems to be related to this retrolambda issue: luontola/retrolambda#48
The text was updated successfully, but these errors were encountered: