On Wed, 7 May 2025 13:22:11 GMT, Raffaello Giulietti <rgiulie...@openjdk.org> 
wrote:

>> src/java.base/share/classes/jdk/internal/access/JavaLangAccess.java line 355:
>> 
>>> 353:      * UTF-16 representation.
>>> 354:      * <p>
>>> 355:      * <b>WARNING: This method does not perform any bound checks.</b>
>> 
>> Maybe not this PR but this method is begging to be renamed. It's really hard 
>> to audit usage when the method is accessible to faraway code via shared 
>> secrets. So maybe not this PR but I think we need an issue in JBS to track 
>> renaming, I think Stuart suggested prefixing with "unchecked".
>
> As mentioned by Alan and Jaikiran, at some point it is advisable to prefix 
> the names with "unchecked".
> 
> For the "noRepl" names, perhaps the mouthful but clearer "noReplacementChar" 
> might help.

@jaikiran, @AlanBateman, implemented `unchecked` method prefix in 4d237efa053.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/24982#discussion_r2078253548

Reply via email to