What is the --release flag in the Java 9 compiler?
Java 9's javac has a new flag --release : > javac --help ... --release <release> Compile for a specific VM version. Supported targets: 6, 7, 8, 9 How is it different from -source and -target flags? Is it just a shortcut for -source X -target X ? Li357 Not exactly. JEP 247: Compile for Older Platform Versions defines this new command-line option, --release : We defined a new command-line option, --release , which automatically configures the compiler to produce class files that will link against an implementation of the given platform version. For the platforms predefined in javac , --release N