Hi all,

`Arrays.copyOf` and `Arrays.copyOfRange` internally use the same function, 
`JVM_CopyOfSpecialArray`. While they both copy arrays, there are some semantic 
differences in parameter checking and exception throwing between the two that 
`JVM_CopyOfSpecialArray` is unable to differentiate. This patch includes:
* Separate error condition checking and exception throwing per method.
* New test cases for each method.

Testing: tier 1.

-------------

Commit messages:
 - Remove debug print.
 - Adhere to API specs.

Changes: https://git.openjdk.org/valhalla/pull/2115/files
  Webrev: https://webrevs.openjdk.org/?repo=valhalla&pr=2115&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8377576
  Stats: 61 lines in 3 files changed: 55 ins; 0 del; 6 mod
  Patch: https://git.openjdk.org/valhalla/pull/2115.diff
  Fetch: git fetch https://git.openjdk.org/valhalla.git pull/2115/head:pull/2115

PR: https://git.openjdk.org/valhalla/pull/2115

Reply via email to