Is it possible to run Java16 code on Android

149 views Asked by At

I know Java 16/17/18 is not compatible with java 8 (android), but is-it a way to generate byte-code for android to execute the program on my phone?

Or trans-code the java16 in an other language for android?

Note: I Use too many "records" to rewrite in java-8

2

There are 2 answers

0
Rasoul Miri On BEST ANSWER
0
Stephen C On

The answer as of now is No.

However, apparently, work is underway to add support for Java 16+ record types to Android; see https://issuetracker.google.com/issues/197081367