On Fri, 30 Jan 2026 03:25:56 GMT, Chen Liang <[email protected]> wrote:
>> src/jdk.compiler/share/classes/com/sun/tools/javac/jvm/ClassWriter.java line
>> 1935:
>>
>>> 1933: }
>>> 1934: if (sym.kind == VAR) {
>>> 1935: if ((flags & STRICT) != 0 || (flags & MARK_STRICT_INIT)
>>> != 0 || types.isNonNullable(sym.type)) {
>>
>> non-nullable fields should have the strict flag in the class file but are
>> different to other, strictly, strict fields. The main difference is that the
>> compiler doesn't automatically place the initializers before the super
>> invocation. This is why I decided to set the strict flag at the end when we
>> are about to write the field into the class file. Setting it in Check would
>> imply, for example, more complex tracking in Flow
>
> Just curious, if we have `!` fields assigned in early construction by
> different branches in if-else, do they generate early-larval/restricted
> frames properly, or are we using proxy locals right now
right now only proxy locals
-------------
PR Review Comment:
https://git.openjdk.org/valhalla/pull/1990#discussion_r2747360129