RFR: 8356439: Rename JavaLangAccess::*NoRepl methods [v4]

Volkan Yazici vyazici at openjdk.org
Mon Sep 1 19:08:44 UTC 2025


On Tue, 19 Aug 2025 14:59:04 GMT, Roger Riggs <rriggs at openjdk.org> wrote:

>> Volkan Yazici has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Remove redundant type parameters
>
> It seems that the API is overloaded trying to satisfy too many requirements, replace/noreplace, throw/nothrow and supporting arbitrary Charsets.  There are multiple callers that only need to create a string from byte array holding latin1.
> They are burdened with catching and ignoring exceptions that do not occur.
> 
> I'm suggesting breaking out that use case in PR#https://github.com/openjdk/jdk/pull/26831.
> That leaves `Files.readString` that needs the full CharSet/noReplace/throw behavior.

@RogerRiggs, @liach, @AlanBateman, I needed to push a `ClassCastException` fix in a69f9fd, which further simplified the sneaky-throws logic in `String`. Would one of you mind, unless you have objections, re-approving the PR, please?

Note that I've attached passing `tier1,2` results to the ticket.

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

PR Comment: https://git.openjdk.org/jdk/pull/26413#issuecomment-3243114718


More information about the security-dev mailing list