[records] Spec for next version of Record Classes JEP
amaembo at gmail.com
Mon Oct 5 04:47:05 UTC 2020
On Sat, Oct 3, 2020 at 12:09 AM Brian Goetz <brian.goetz at oracle.com> wrote:
> I think we're reaching diminishing returns here.
Well, to me, it's not diminishing. It's certainly a piece of code that
will not have any effect after compilation, so it's a mistake.
Reporting it is not that hard. Having a class/runtime annotation in
source code that disappears completely in the compiled class-file
without any warning sounds confusing and may cause subtle problems.
Well, of course, we can create an inspection in IntelliJ IDEA to warn
about these cases, and people will like IntelliJ IDEA even more, but I
believe it's a compiler job to reject this, like Java already does
with e.g. unreachable code.
With best regards,
More information about the amber-spec-experts