On Thu, 18 Jun 2026 16:01:43 GMT, Naoto Sato <[email protected]> wrote:
>> Jaikiran Pai has updated the pull request with a new target base due to a
>> merge or a rebase. The incremental webrev excludes the unrelated changes
>> brought in by the merge/rebase. The pull request contains three additional
>> commits since the last revision:
>>
>> - print mismatched content
>> - merge latest from master branch
>> - 8386810: Improve debuggability of
>> test/jdk/sun/nio/cs/TestStringCodingUTF8.java
>
> test/jdk/sun/nio/cs/TestStringCodingUTF8.java line 201:
>
>> 199: final StringBuilder sb = new StringBuilder();
>> 200: sb.append("Index=").append(i).append(", expected=");
>> 201: if (i > expected.length) {
>
> Should this exclude `expected.length`? ie, `i >= expected.length`?
Indeed, good catch. I've now updated the PR to address this part.
I have also manually verified that before the change in the latest commit, this
printing code would run into IndexOutOfBoundsException if the array sizes were
different and the mismatch happened at the end of one array. With the fix
pushed in the latest commit, that is now addressed.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/31548#discussion_r3437415661