--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Preview.java Thu Jun 06 12:24:44 2019 -0300
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/code/Preview.java Thu Jun 06 12:24:44 2019 -0300
@@ -167,7 +167,8 @@
public boolean isPreview(Feature feature) {
if (feature == Feature.SWITCH_EXPRESSION ||
feature == Feature.SWITCH_MULTIPLE_CASE_LABELS ||
- feature == Feature.SWITCH_RULE)
+ feature == Feature.SWITCH_RULE ||
+ feature == Feature.TEXT_BLOCKS)
return true;
//Note: this is a backdoor which allows to optionally treat all features as 'preview' (for testing).
//When real preview features will be added, this method can be implemented to return 'true'