Use Arrays.copyOf and Arrays.copyOfRange where possible

Closes gh-23393
This commit is contained in:
stsypanov
2019-07-31 19:17:22 +03:00
committed by Sam Brannen
parent 216ffcfe62
commit 78d56dc61b
5 changed files with 6 additions and 12 deletions

View File

@@ -501,9 +501,7 @@ class Tokenizer {
}
private char[] subarray(int start, int end) {
char[] result = new char[end - start];
System.arraycopy(this.charsToProcess, start, result, 0, end - start);
return result;
return Arrays.copyOfRange(this.charsToProcess, start, end);
}
/**