RFR: 8366765: [REDO] Rename JavaLangAccess::*NoRepl methods [v2]

Volkan Yazici vyazici at openjdk.org
Thu Sep 4 11:25:53 UTC 2025


On Thu, 4 Sep 2025 10:03:10 GMT, Andrey Turbanov <aturbanov at openjdk.org> wrote:

>> Volkan Yazici has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Improve docs
>
> src/java.base/share/classes/java/lang/String.java line 961:
> 
>> 959:      * @throws CharacterCodingException For malformed input or unmappable characters
>> 960:      */
>> 961:     static byte[] getBytesUTF8OrThrow(String s) throws CharacterCodingException {
> 
> `encodeUTF8OrThrow(s.coder(), s.value());` specified to throw `UnmappableCharacterException`. May we should to it here too?

UCE extends from CCE, hence `throws UCE` is already covered. Plus, what I see from `JLA::*OrThrow` methods, we only declare and document the CCE, not its subclasses.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27084#discussion_r2321722048


More information about the security-dev mailing list