< prev index next >

src/java.compiler/share/classes/javax/lang/model/SourceVersion.java

Print this page

        

@@ -56,13 +56,12 @@
      * 1.7: diamond syntax, try-with-resources, etc.
      * 1.8: lambda expressions and default methods
      *   9: modules, small cleanups to 1.7 and 1.8 changes
      *  10: local-variable type inference (var)
      *  11: local-variable syntax for lambda parameters
-     *  12: no changes (switch expressions were in preview)
-     *  13: no changes (switch expressions and text blocks in preview)
-     *  14: TBD
+     *  12: no changes (switch expressions in preview)
+     *  13: TBD
      */
 
     /**
      * The original version.
      *

@@ -191,30 +190,22 @@
      * The version recognized by the Java Platform, Standard Edition
      * 13.
      *
      * @since 13
      */
-     RELEASE_13,
-
-    /**
-     * The version recognized by the Java Platform, Standard Edition
-     * 14.
-     *
-     * @since 14
-     */
-     RELEASE_14;
+     RELEASE_13;
 
     // Note that when adding constants for newer releases, the
     // behavior of latest() and latestSupported() must be updated too.
 
     /**
      * Returns the latest source version that can be modeled.
      *
      * @return the latest source version that can be modeled
      */
     public static SourceVersion latest() {
-        return RELEASE_14;
+        return RELEASE_13;
     }
 
     private static final SourceVersion latestSupported = getLatestSupported();
 
     /*

@@ -225,11 +216,11 @@
      * need to be updated accordingly.
      */
     private static SourceVersion getLatestSupported() {
         int intVersion = Runtime.version().feature();
         return (intVersion >= 11) ?
-            valueOf("RELEASE_" + Math.min(14, intVersion)):
+            valueOf("RELEASE_" + Math.min(13, intVersion)):
             RELEASE_10;
     }
 
     /**
      * Returns the latest source version fully supported by the

@@ -264,12 +255,12 @@
      * of an initial character for which {@link
      * Character#isJavaIdentifierStart(int)} returns {@code true},
      * followed only by characters for which {@link
      * Character#isJavaIdentifierPart(int)} returns {@code true}.
      * This pattern matches regular identifiers, keywords, restricted
-     * keywords, restricted identifiers and the literals {@code "true"},
-     * {@code "false"}, {@code "null"}.
+     * keywords, and the literals {@code "true"}, {@code "false"},
+     * {@code "null"}, and {@code "var"}.
      *
      * The method returns {@code false} for all other strings.
      *
      * @param name the string to check
      * @return {@code true} if this string is a

@@ -302,11 +293,11 @@
      * qualified name in the latest source version.  Unlike {@link
      * #isIdentifier isIdentifier}, this method returns {@code false}
      * for keywords, boolean literals, and the null literal.
      *
      * This method returns {@code true} for <i>restricted
-     * keywords</i> and <i>restricted identifiers</i>
+     * keywords</i> and {@code "var"}.
      *
      * @param name the string to check
      * @return {@code true} if this string is a
      * syntactically valid name, {@code false} otherwise.
      * @jls 3.9 Keywords

@@ -321,11 +312,11 @@
      * qualified name in the given source version.  Unlike {@link
      * #isIdentifier isIdentifier}, this method returns {@code false}
      * for keywords, boolean literals, and the null literal.
      *
      * This method returns {@code true} for <i>restricted
-     * keywords</i> and <i>restricted identifiers</i>
+     * keywords</i> and {@code "var"}.
      *
      * @param name the string to check
      * @param version the version to use
      * @return {@code true} if this string is a
      * syntactically valid name, {@code false} otherwise.

@@ -345,11 +336,11 @@
 
     /**
      * Returns whether or not {@code s} is a keyword, boolean literal,
      * or null literal in the latest source version.
      * This method returns {@code false} for <i>restricted
-     * keywords</i> and <i>restricted identifiers</i>.
+     * keywords</i> and {@code "var"}.
      *
      * @param s the string to check
      * @return {@code true} if {@code s} is a keyword, or boolean
      * literal, or null literal, {@code false} otherwise.
      * @jls 3.9 Keywords

@@ -362,11 +353,11 @@
 
     /**
      * Returns whether or not {@code s} is a keyword, boolean literal,
      * or null literal in the given source version.
      * This method returns {@code false} for <i>restricted
-     * keywords</i> and <i>restricted identifiers</i>.
+     * keywords</i> and {@code "var"}.
      *
      * @param s the string to check
      * @param version the version to use
      * @return {@code true} if {@code s} is a keyword, or boolean
      * literal, or null literal, {@code false} otherwise.
< prev index next >