On Tue, 3 Sep 2024 14:32:16 GMT, Shaojin Wen <s...@openjdk.org> wrote:

>> We might rename these to `countAscii` and `countModifiedUtf8Compatible`.
>
> ascii includes '\0', `CountModifiedUtf8Compatible` Newbies don't seem to know 
> what it means

I think naming internal low-level methods based precisely on what they do 
rather than their intended purpose is fine: we're counting positives and zeros 
in a byte array. Good! Higher level API methods called `isAscii(byte[] 
utf8Bytes)` et.c. which calls the low-level methods? Also good!

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

PR Review Comment: https://git.openjdk.org/jdk/pull/20772#discussion_r1742225537

Reply via email to