Skip to content

Commit

Permalink
remove unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
wenshao committed Jan 22, 2025
1 parent 0451d5c commit 9f9a017
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions core/src/main/java/com/alibaba/fastjson2/util/IOUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -1665,17 +1665,6 @@ public static int indexOfSlashV(byte[] value, int fromIndex, int max) {
return indexOfChar0(value, '\\', i, max);
}

public static int indexOfChar(byte[] value, int ch, int fromIndex, int max) {
if (INDEX_OF_CHAR_LATIN1 == null) {
return indexOfChar0(value, ch, fromIndex, max);
}
try {
return (int) INDEX_OF_CHAR_LATIN1.invokeExact(value, ch, fromIndex, max);
} catch (Throwable e) {
throw new JSONException(e.getMessage());
}
}

private static int indexOfChar0(byte[] value, int ch, int fromIndex, int max) {
for (int i = fromIndex; i < max; i++) {
if (value[i] == ch) {
Expand Down

0 comments on commit 9f9a017

Please sign in to comment.