3 ms·
You know you can use Android N (and later) and still target Android 19 and still use lambdas, right? Or did you mean something else? Maybe the developer page co
by nurettin 9y ago
You know you can use Android N (and later) and still target Android 19 and still use lambdas, right? Or did you mean something else? Maybe the developer page confused you. Can you clarify this for me?
And yes, I know you can't use all features of java 8, but this isn't what the posts are on about. They just ignore all facts and go straight to "android is stuck at java 6" and nobody really challenges them on this belief. I guess neither will you.
- pjmlp 9y agoI do have Android development experience, but I have more Java experience all the way back to the early JDK releases, including having read enough papers about several JVM implementations. The issue regarding lambdas has to do how they are implemented, by making use of inner classes instead of doing what Oracle has done in Hotspot and is being followed by most third party JVM implementations, meaning making use of invokedynamic infrastructure, thus being as if there was special bytecodes for lambdas. This allows for more performance and optimization opportunities, which are much harder to achieve with plain inner classes. Also those of us that like Java, always mean both the language and platform when talking about Java. The current situation is that now we need to write Android specific libraries instead of being able to pick any random Java 7 or 8 library and use it on Android applications, without any change.
- nurettin 9y agoJust so we are on the same page, I'm on about the feature superstructure, not the "implementation details for those of us that like java and always mean hotspot-like technologies when having a conversation about android language features".
- pjmlp 9y agoYeah, but those implementation details are leaky abstractions about the Java 8 feature superstructure performance on Android, and what Java 8 libraries are usable straight out of Maven repositories.