RFR: 8174840: Elements.overrides does not check the return type of the methods
Pavel Rappo
prappo at openjdk.org
Mon Jan 6 22:31:34 UTC 2025
On Mon, 6 Jan 2025 11:56:59 GMT, Nizar Benalla <nbenalla at openjdk.org> wrote:
>> src/java.compiler/share/classes/javax/lang/model/util/Elements.java line 785:
>>
>>> 783: * specified in JLS {@jls 8.4.8.1} and {@jls 8.4.8.3}. In particular, the additional constraints
>>> 784: * on thrown types, return types and those constraints on method modifiers not directly
>>> 785: * bound to the overriding relation as such.
>>
>> Suggestion:
>>
>> * on exception types, return types, and method modifiers do not affect
>> * the overriding relation.
>>
>>
>> The original wording has grammatical mistake and makes no sense.
>
> I don't agree that it makes no sense but I find this wording simpler, so I'll use it instead.
I would strongly recommend to wait for @jddarcy to review that.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/22920#discussion_r1904701599
More information about the compiler-dev
mailing list