[lworld] Integrated: 8368795: [lworld] javac rejects assignments to components of array fields with initializers in the prologue

Vicente Romero vromero at openjdk.org
Thu Oct 9 13:22:36 UTC 2025


On Mon, 6 Oct 2025 16:01:39 GMT, Vicente Romero <vromero at openjdk.org> wrote:

> there are some cases for which a proxy variable should be generated by javac but it is not. When this happens, the generated class won't pass the verifier. Setting an array component in the prologue is one of those cases but also assigning to a field of an instance field like:
> 
> value class Test {
>     static class Foo { 
>         int x;
>     }
>     private final Foo data = new Foo();
>     Test() {
>         data.x = 12;
>         super();
>     }
> }

This pull request has now been integrated.

Changeset: dd39de49
Author:    Vicente Romero <vromero at openjdk.org>
URL:       https://git.openjdk.org/valhalla/commit/dd39de49a52a93d811206b5d3c369de47fffc464
Stats:     143 lines in 3 files changed: 54 ins; 81 del; 8 mod

8368795: [lworld] javac rejects assignments to components of array fields with initializers in the prologue

Reviewed-by: liach

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

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


More information about the valhalla-dev mailing list