Fix null checking when copying from flat arrays to reference arrays. Previously, `FlatArrayKlass::copy_array` called `obj_at_put` without `CHECK`. As aresult, the runtime check for null-restricted arrays was bypassed.
A new test has been added to verify this behaviour. Thanks. --------- - [x] I confirm that I make this contribution in accordance with the [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai). ------------- Commit messages: - Remove redundant VM options in the test class - Add test - 8382937: [lworld] System.arraycopy can copy null into a null-restricted array Changes: https://git.openjdk.org/valhalla/pull/2577/files Webrev: https://webrevs.openjdk.org/?repo=valhalla&pr=2577&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8382937 Stats: 63 lines in 2 files changed: 62 ins; 0 del; 1 mod Patch: https://git.openjdk.org/valhalla/pull/2577.diff Fetch: git fetch https://git.openjdk.org/valhalla.git pull/2577/head:pull/2577 PR: https://git.openjdk.org/valhalla/pull/2577
