Open DanTup opened 1 week ago
Summary: The VM crashes when evaluating a named record field of a late
variable that hasn't been initialized yet. This occurs when trying to access the a
field of x
in the debugger, even though x
is declared as late
and hasn't been assigned a value.
//cc @derekxu16
Per discussion in the CFE sync meeting the general conclusion was
Another option discussed in the triaged meeting was to implement initialization of late variables during expression evaluation and make the functionality similar to how we deal with non late variables. There would still be a number of issues with side effects that would be similar to the situation that we have today with non late variables.
Given this code, and a breakpoint on the marked line:
If you try to evaluate
x.a
(which at this point isn't initialized, though I hoped it would trigger initialization), the VM crashes with this error: