It has been confirmed up to Java10 (as of 2018/08/01).
javap -v file.class | grep "major version" | awk '{ print $3 - 44 }'
The major version value displayed by the javap -v
command seems to be the" supported class version "(≠ Java version).
The class version is "Java version +44", so you can subtract it.
Java maintains compatibility = supports all previous "supported class versions" It seems like that.
It is unclear what will happen after Java 9 because the versioning method will change. Will there be a beta version of the future version someday?
It seems that the version notation after Java 10 is as ↓.
I don't know how it actually comes out with java -version
, but for reference.
https://qiita.com/nowokay/items/d9bc4b3f715d17c2830d#322-time-based-release-versioning
Recommended Posts