On Wed, 28 Jun 2023 01:45:51 GMT, Chen Liang <li...@openjdk.org> wrote:

> On a side note, `NoRepl` means "no replication", implying the passed array is 
> already trusted. I think you should do something like this instead:

I think `NoRepl` means "no replace", it's an ambiguous acronym.

It cannot be replaced by `new String(byte[], int, int, Charset)` because the 
constructor will replaces malformed-input and unmappable-character sequences 
with this charset's default replacement string.

I think throwing an exception when malformed or unmappable bytes is encountered 
is a useful behavior, and maybe a new public API should be provided to users.

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

PR Comment: https://git.openjdk.org/jdk/pull/14655#issuecomment-1611031664

Reply via email to