changeset 49134:ac07f694a521 switch

Enabling indy switch desugaring by default, except for java.base (where it may cause bootstrap issues).
author jlahoda
date Fri, 09 Feb 2018 14:37:00 +0100
parents c9c66cfdae9b
children 2b837643a2d4
files make/CompileJavaModules.gmk src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Lower.java test/langtools/tools/javac/switchnull/SwitchNull.java
diffstat 3 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/make/CompileJavaModules.gmk	Fri Feb 09 13:05:07 2018 +0100
+++ b/make/CompileJavaModules.gmk	Fri Feb 09 14:37:00 2018 +0100
@@ -42,7 +42,7 @@
 
 ################################################################################
 
-java.base_ADD_JAVAC_FLAGS += -Xdoclint:all/protected,-reference '-Xdoclint/package:java.*,javax.*' -XDstringConcat=inline
+java.base_ADD_JAVAC_FLAGS += -Xdoclint:all/protected,-reference '-Xdoclint/package:java.*,javax.*' -XDstringConcat=inline -XDdisableIndySwitch=true
 java.base_COPY += .icu .dat .spp content-types.properties hijrah-config-islamic-umalqura.properties
 java.base_CLEAN += intrinsic.properties
 
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Lower.java	Fri Feb 09 13:05:07 2018 +0100
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Lower.java	Fri Feb 09 14:37:00 2018 +0100
@@ -126,7 +126,7 @@
         debugLower = options.isSet("debuglower");
         pkginfoOpt = PkgInfo.get(options);
         
-        generateNewSwitch = options.isSet("enableIndySwitch") && target.hasSwichBootstraps();
+        generateNewSwitch = !options.isSet("disableIndySwitch") && target.hasSwichBootstraps();
     }
 
     /** The currently enclosing class.
--- a/test/langtools/tools/javac/switchnull/SwitchNull.java	Fri Feb 09 13:05:07 2018 +0100
+++ b/test/langtools/tools/javac/switchnull/SwitchNull.java	Fri Feb 09 14:37:00 2018 +0100
@@ -2,7 +2,7 @@
  * @test
  * @compile SwitchNull.java
  * @run main SwitchNull
- * @compile -XDenableIndySwitch SwitchNull.java
+ * @compile -XDdisableIndySwitch=true SwitchNull.java
  * @run main SwitchNull
  */