Don't use removed Character::codePointCount overload

This commit is contained in:
Tatsunori Uchino 2026-01-29 03:44:51 +00:00
parent 2cf8f448ed
commit 5df93771f2
2 changed files with 5 additions and 6 deletions

View File

@ -389,8 +389,7 @@ public class Supplementary {
* Test codePointCount(int, int) &
* codePointCount()
*
* This test case assumes that Character.codePointCount() &
* Character.codePointCount(CharSequence, int, int) works
* This test case assumes that Character.codePointCount(CharSequence, int, int) works
* correctly.
*/
static void test8() {
@ -421,7 +420,7 @@ public class Supplementary {
}
int result = str.codePointCount();
int expected = Character.codePointCount(str);
int expected = Character.codePointCount(str, 0, str.length());
check(result != expected, "substring:codePointCount()", result, expected);
// test exceptions

View File

@ -218,8 +218,8 @@ public class Supplementary {
* Test codePointCount(int, int) & codePointCount()
*
* This test case assumes that
* Character.codePointCount(CharSequence, int, int) &
* Character.codePointCount(CharSequence) works correctly.
* Character.codePointCount(CharSequence, int, int) works
* correctly.
*/
static void test5() {
for (int i = 0; i < input.length; i++) {
@ -241,7 +241,7 @@ public class Supplementary {
int result = sb.codePointCount();
int expected = Character.codePointCount(sb);
int expected = Character.codePointCount(sb, 0, sb.length());
check(result != expected, "codePointCount()", result, expected);
// test exceptions