--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/tree/TreeTranslator.java Sun Jun 09 15:48:57 2019 -0700
+++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/tree/TreeTranslator.java Mon Jun 10 05:09:52 2019 +0200
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2019, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -258,8 +258,11 @@
}
public void visitBreak(JCBreak tree) {
- if (tree.isValueBreak())
- tree.value = translate(tree.value);
+ result = tree;
+ }
+
+ public void visitYield(JCYield tree) {
+ tree.value = translate(tree.value);
result = tree;
}