JDK-8193351 : Add SourceVersion.RELEASE_11
  • Type: CSR
  • Component: core-libs
  • Sub-Component: javax.lang.model
  • Priority: P4
  • Status: Closed
  • Resolution: Approved
  • Submitted: 2017-12-12
  • Updated: 2018-06-19
  • Resolved: 2017-12-14
Related Reports
CSR :  
Relates :  
Relates :  
Description
Summary
-------

Add a new enum constant `RELEASE_11` to `javax.lang.model.SourceVersion` for the JDK 11 release.

Problem
-------

The `SourceVersion` enum needs an enum constant for each release being modeled.

Solution
--------

Add the enum constant `RELEASE_11`.

Specification
-------------

    --- old/src/java.compiler/share/classes/javax/lang/model/SourceVersion.java	2017-12-11 22:32:47.930062197 -0800
    +++ new/src/java.compiler/share/classes/javax/lang/model/SourceVersion.java	2017-12-11 22:32:47.586062182 -0800
    @@ -159,7 +159,15 @@
          *
          * @since 10
          */
    -     RELEASE_10;
    +     RELEASE_10,
    +
    +    /**
    +     * The version recognized by the Java Platform, Standard Edition
    +     * 11.
    +     *
    +     * @since 11
    +     */
    +     RELEASE_11;

Also, the output of `SourceVersion.latest()` is changed to `RELEASE_11`.


Comments
Voting to approve.
14-12-2017

(Adding Sundar as a reviewer in the reviewer field.)
14-12-2017

Reviewed. -Sundar
14-12-2017