<div dir="auto">+1</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Feb 17, 2024, 15:37 John Hendrikx <<a href="mailto:john.hendrikx@gmail.com">john.hendrikx@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">+1<br>
<br>
On 16/02/2024 23:11, Kevin Rushforth wrote:<br>
> All,<br>
><br>
> Even though we build JavaFX binaries with JDK 21 as the boot JDK, the <br>
> latest version of JavaFX still runs with JDK 17, although it isn't <br>
> tested with older JDK versions. In order for JavaFX to be able to use <br>
> newer JDK features, such as code snippets (in API docs), record <br>
> patterns, pattern matching for switch statements, and so forth, we <br>
> need to increase the minimum version of the JDK that can run the <br>
> latest JavaFX. Additionally, there is an ongoing cost to keeping <br>
> JavaFX buildable and runnable on older versions of Java, and very <br>
> little reason to continue to do so.<br>
><br>
> A question was raised [1] as to whether we should go even further and, <br>
> once JDK 22 is released, jump straight to JDK 22 as a minimum. While <br>
> we could do that, I feel that there isn't sufficient justification for <br>
> this at this time, although we could reconsider for next release.<br>
><br>
> To this end, I propose to bump the minimum version of the JDK needed <br>
> to run JavaFX 23 to JDK 21. I filed JDK-8321603 [2] to track this and <br>
> prepared PR #1370 [3] (I've moved the PR back to Draft, pending this <br>
> discussion). This will not affect update releases of earlier versions <br>
> of JavaFX (e.g., JavaFX 21.0.NN or JavaFX 17.0.NN), which will <br>
> continue to run with the same minimum JDK that they run on today.<br>
><br>
> As a reminder, we only assure that JavaFX NN will run with JDK NN-1 or <br>
> later, although in practice, we don't bump the minimum required JDK <br>
> version without a good reason. For example, while JavaFX 22 is built <br>
> using JDK 21 as the boot JDK, it produces class files that will run <br>
> with JDK 17, using "--release 17". The proposed change discussed here <br>
> would update that in JavaFX 23 to "--release 21".<br>
><br>
> NOTE: this will not be an invitation to do wholesale refactoring of <br>
> existing classes or methods to use newer language features (e.g., a PR <br>
> that refactors existing switch statements and switch expressions into <br>
> pattern-matching switch expressions would not be welcome). Rather, <br>
> this can be seen as enabling judicious use of new features in new <br>
> code, much as we did when we started allowing the use of "var", <br>
> records, and pattern-matching instanceof.<br>
><br>
> Comments are welcome.<br>
><br>
> -- Kevin<br>
><br>
> [1] <br>
> <a href="https://mail.openjdk.org/pipermail/openjfx-dev/2023-December/044081.html" rel="noreferrer noreferrer" target="_blank">https://mail.openjdk.org/pipermail/openjfx-dev/2023-December/044081.html</a><br>
> [2] <a href="https://bugs.openjdk.org/browse/JDK-8321603" rel="noreferrer noreferrer" target="_blank">https://bugs.openjdk.org/browse/JDK-8321603</a><br>
> [3] <a href="https://github.com/openjdk/jfx/pull/1370" rel="noreferrer noreferrer" target="_blank">https://github.com/openjdk/jfx/pull/1370</a><br>
><br>
</blockquote></div>