JDK 13 RFR of JDK-8221264: Refactor SourceVersion#latestSupported

Joe Darcy joe.darcy at oracle.com
Sat Mar 23 19:31:14 UTC 2019


PS

On 3/23/2019 11:11 AM, Joe Darcy wrote:

[snip]

> Also, since the feature method was added in JDK 10, I tightened the 
> returned range to be JDK 10 or later.
>
> I didn't do so in this patch, but it would be reasonable to bump
>
>     {@code RELEASE_5} or later must be returned.
>
> to RELEASE_8 or later since the API using JDK 8 language features.
>
And with defining a module, the API is using 9-level language features 
so might as well do

-     * current execution environment.  {@code RELEASE_5} or later must
+     * current execution environment.  {@code RELEASE_9} or later must

at this time and run a CSR for the change once all the wording has been 
agreed to.

 From a quick check, the java.compiler API will compile down to JDK 9 
other than the Runtime.Version.feature() method which as added in JDK 
10. (A different implementation could use a now deprecated 
Runtime.Version method to compile on JDK 9, but I don't think this is 
necessary or desirable in the implementation.)

Thanks,

-Joe




More information about the compiler-dev mailing list