On Tue, Jul 19, 2022 at 10:15 AM Karl Heinz Marbaise <khmarba...@gmx.de> wrote: > On 19.07.22 19:10, Tamás Cservenák wrote: > > Actually, yes, I keep forgetting about release flag: so, if running on > > LTS, user can do: > > - use compiler "release" flag to target any Java from 8 to 17 (up to > > current LTS it runs on) > > You can build for target JDK 7 with JDK17 via --release ... > and also not ONLY on LTS release of JDK you can use also non LTS > versions for that...
This only affects the generated bytecode, though? If you use anything only available in a later JDK then your app/library will fail at runtime, i.e. once it hits something that is actually _running_ the older JDK. Perhaps things have improved in this area but when we tried this (years ago), it was a pain. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org For additional commands, e-mail: dev-h...@maven.apache.org