On Thu, 14 May 2026 19:17:34 GMT, Frederic Parain <[email protected]> wrote:
>> Here's a patch adding argument validation to the factories for the special >> arrays. >> It also aligns the semantic of these factories with other ways to create >> arrays with respect to the initialization state of the element type. >> Some compiler tests needed adjustments because of the new code shape of the >> factories. >> >> Thank you. >> >> --------- >> - [X] I confirm that I make this contribution in accordance with the >> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai). > > Frederic Parain has updated the pull request incrementally with one > additional commit since the last revision: > > Restore blank lines Looks good to me otherwise. Thanks for working on this Fred! src/java.base/share/classes/jdk/internal/value/ValueClass.java line 90: > 88: } > 89: if (length < 0) { > 90: throw new IllegalArgumentException("Array length is negative"); Indentation is incorrect here. test/hotspot/jtreg/compiler/valhalla/inlinetypes/TestIntrinsics.java line 1780: > 1778: @Test > 1779: @IR(failOn = {STATIC_CALL_OF_METHOD, > "jdk.internal.value.ValueClass::isFlatArray"}) > 1780: @IR(failOn = {STATIC_CALL_OF_METHOD, > "jdk.internal.value.ValueClass::isFlatArray0"}) You can just use a comma separated list here. I.e. something like @IR(failOn = {STATIC_CALL_OF_METHOD, "jdk.internal.value.ValueClass::isFlatArray", STATIC_CALL_OF_METHOD, "jdk.internal.value.ValueClass::isFlatArray0"}) test/hotspot/jtreg/runtime/valhalla/inlinetypes/TestArrayFactories.java line 291: > 289: m.invoke(null); > 290: } catch (Throwable t) { > 291: t.printStackTrace(); Indentation is incorrect here and in surrounding code. ------------- Marked as reviewed by thartmann (Committer). PR Review: https://git.openjdk.org/valhalla/pull/2435#pullrequestreview-4298131378 PR Review Comment: https://git.openjdk.org/valhalla/pull/2435#discussion_r3248185298 PR Review Comment: https://git.openjdk.org/valhalla/pull/2435#discussion_r3248194683 PR Review Comment: https://git.openjdk.org/valhalla/pull/2435#discussion_r3248202148
