FYI, proposed javax.lang.model changes for records

Vicente Romero vicente.romero at oracle.com
Mon Oct 7 20:59:03 UTC 2019


Hi,

We have recently made an update of the javax.lang.model implementation 
for records [1]. The key difference with the previous implementation is 
that we have made javax.lang.model.element.RecordComponentElement, a top 
level element in the model, a direct subinterface of j.l.m.e.Element. 
Previously it was extending j.l.m.e.VariableElement. Doing this 
seemingly minor change has implied a cascade of changes several existing 
APIs plus the addition of several new ones: new visitors, new scanners, 
etc. A specdiff of the changes comprised in this iteration can be seen 
at [2]. As a baseline I have also provided a specdiff of all the changes 
done in javax.lang.model for records at [3]. This last diff is a 
comparison between current JDK14 implementation and our proposal for 
records,

Thanks,
Vicente

[1] https://hg.openjdk.java.net/amber/amber/rev/cf64ea74503e
[2] 
http://cr.openjdk.java.net/~vromero/amber/records/javax.lang.model/diff_initial_and_current_approach/specdiff.01/java.compiler/module-summary.html
[3]http://cr.openjdk.java.net/~vromero/amber/records/javax.lang.model/specdiff.00/java.compiler/module-summary.html 



More information about the compiler-dev mailing list