diff --git a/core/src/main/java/com/alibaba/fastjson2/util/IOUtils.java b/core/src/main/java/com/alibaba/fastjson2/util/IOUtils.java index 441802923..e5c49ffdb 100644 --- a/core/src/main/java/com/alibaba/fastjson2/util/IOUtils.java +++ b/core/src/main/java/com/alibaba/fastjson2/util/IOUtils.java @@ -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) {