RFR: 8194743: Compiler implementation for Statements before super() [v16]
Archie Cobbs
acobbs at openjdk.org
Thu Sep 28 16:19:10 UTC 2023
On Thu, 28 Sep 2023 10:13:19 GMT, Gavin Bierman <gbierman at openjdk.org> wrote:
>> For instance:
>>
>>
>> explicit constructor invocation may only appear within constructors
>>
>>
>>
>> redundant explicit constructor invocation
>>
>>
>>
>> explicit constructor invocation not allowed here
>>
>>
>>
>> 'return'' not allowed before explicit constructor invocation
>
> @mcimadamore Yes, I like the first. Something like "explicit constructor invocation may only appear within a constructor body" is good.
>
> (The JLS actually says that an (explicit) constructor invocation, i.e. this(...) or super(...), is not a statement, but just a thing that can appear in a constructor body.)
Updated error messages in 738c10a57de.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/13656#discussion_r1340385904
More information about the compiler-dev
mailing list