On Fri, 17 Oct 2025 22:26:11 GMT, Vicente Romero <[email protected]> wrote:
> For code like:
>
>
> value class Test {
> static class Foo {
> int x;
> int getX() { return x; }
> }
> private final Foo data = new Foo();
> Test() {
> data.getX();
> super();
> }
> }
>
>
> javac generates code corresponding to the initialization of field `data`
> twice, which is incorrect
This pull request has now been integrated.
Changeset: 204f8036
Author: Vicente Romero <[email protected]>
URL:
https://git.openjdk.org/valhalla/commit/204f8036cc1f96a636e0071af89701e439d23056
Stats: 149 lines in 3 files changed: 66 ins; 60 del; 23 mod
8369860: [lworld] Javac generates duplicate initializer code
-------------
PR: https://git.openjdk.org/valhalla/pull/1686