RFR: JDK-8205913: Inconsistent source code model

Jan Lahoda jan.lahoda at oracle.com
Wed Jun 27 14:10:09 UTC 2018


Hi,

For code like:
for (name : names) { }

javac creates a VariableTree for "name", but it has null modifiers and 
name, which appears to be inconsistent with other similar cases. So the 
proposal is to change this so that there are non-null modifiers and 
non-null name (<error>).

Webrev: http://cr.openjdk.java.net/~jlahoda/8205913/webrev.00/
Bug: https://bugs.openjdk.java.net/browse/JDK-8205913

Any feedback is welcome.

Thanks,
     Jan


More information about the compiler-dev mailing list