import jdk.internal.vm.annotation.NullRestricted;
import jdk.internal.vm.annotation.Strict;

public class Test {
    static value class MyValue1 {
        int i = 42;
        @Strict
        @NullRestricted
        MyValue2 val2 = new MyValue2();
    }

    static value class MyValue2 {
        long l0;
        long l1;

        private MyValue2() {
            l0 = 42;
            l1 = 43;
        }
    }

    @Strict
    @NullRestricted
    MyValue1 val1 = new MyValue1();

    public long test() {
        return val1.val2.l0;
    }

    public static void main(String[] args) {
        Test t = new Test();
        for (int i = 0; i < 100_000; ++i) {
            t.test();
        }
    }
}

