RFR: 8313435: Clean up unused default methods code [v5]
Coleen Phillimore
coleenp at openjdk.org
Fri Aug 4 14:28:46 UTC 2023
On Fri, 4 Aug 2023 01:42:34 GMT, Ioi Lam <iklam at openjdk.org> wrote:
>> Coleen Phillimore has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Make assert an exception.
>
> src/hotspot/share/classfile/bytecodeAssembler.cpp line 51:
>
>> 49: index = *probe;
>> 50: }
>> 51: return static_cast<u2>(index + _orig->length());
>
> The two static_cast<u2>'s should be changed to checked_cast<u2> since we know that we will never truncate.
If we know they're always in range, then why check? Changed them.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15095#discussion_r1284488176
More information about the hotspot-runtime-dev
mailing list