You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Enum-constructor payload args are not marked consumed: V(x) then W(x) silently reads x's blanked slot #764
Under the flip, Token.Text(a) moves a (payload owned by the constructed value) but SemaCheck never marks the consumption — neither check_enum_variant (NK_ENUM_VARIANT arm, no mark_moved_if_consumed on payload args, contrast struct-literal fields at ~11654 and collection elements at ~11337) nor check_call's variant_payload_tys branch (~14732). A second use compiles clean and reads the move-blanked slot at runtime: 6-line repro in with-staging/fixpoint-analysis (ctor_move.w — checks 'ok' today); behavior symptom = issue65_fstring_mixed_holes' empty Bad() payload (exit-134 census entry).
HAZARD (learned tonight, do not naively widen): adding mark_moved_if_consumed at both sites compiles the tree clean (seed gate green) but the resulting compiler misbehaves at runtime (CLI arg parsing corrupted) — the marking drives move-reset emission and some compiler-source pattern gets a reset the checker's liveness modeled differently. This is the #695/#696 per-edge move-transfer drift class: the fix must land ALONE in a :move-audit/:drop-audit-bracketed batch, with the reset-placement divergence root-caused first (tools/move_audit.w baseline against the pre-change compiler).
Census attribution: test/behavior/issue65_fstring_mixed_holes.w is this defect at runtime — let tok = Token.Text(label); let err = LocalErr.Bad(label) reuses a payload the first ctor already moved; MirLower blanks label, the checker never marks it, output is err=Bad() (assert at :16). When the checker-side marking lands (isolated :move-audit batch per the protocol above), this test must be respelled to clone/materialize the second use — it will correctly become a use-after-move error.
Fixed on 747-flip in 419eefd as its own isolated batch per the protocol above. Both sites (check_enum_variant + the static-variant method-call path) now apply the #714 container-store rule with the method_arg_stores_value guards. The prior attempt's runtime CLI corruption did NOT reproduce — build -o/run/test/argv-forwarding all exercised green; the interacting defect was among the session-3 fixes (clause keying / sidecar records). Batch bracket: build rc=0, fixpoint rc=0, move-audit rc=0 (ground truth), drop-audit rc=0 (vs seed baseline), debug-alloc 64 PASS / 0 FAIL, :test failures unchanged-known (17, all #761 release-lane + derives). issue65_fstring_mixed_holes respelled + green; err_ctor_payload_reuse pins the diagnostic.
Activity
ehartford commentedon Aug 10, 2026
Census attribution: test/behavior/issue65_fstring_mixed_holes.w is this defect at runtime —
let tok = Token.Text(label); let err = LocalErr.Bad(label)reuses a payload the first ctor already moved; MirLower blankslabel, the checker never marks it, output iserr=Bad()(assert at :16). When the checker-side marking lands (isolated :move-audit batch per the protocol above), this test must be respelled to clone/materialize the second use — it will correctly become a use-after-move error.docs: handoff final — five gates green on ae91424, census 102→5 (4 Er…
ehartford commentedon Aug 11, 2026
Fixed on 747-flip in 419eefd as its own isolated batch per the protocol above. Both sites (check_enum_variant + the static-variant method-call path) now apply the #714 container-store rule with the method_arg_stores_value guards. The prior attempt's runtime CLI corruption did NOT reproduce — build -o/run/test/argv-forwarding all exercised green; the interacting defect was among the session-3 fixes (clause keying / sidecar records). Batch bracket: build rc=0, fixpoint rc=0, move-audit rc=0 (ground truth), drop-audit rc=0 (vs seed baseline), debug-alloc 64 PASS / 0 FAIL, :test failures unchanged-known (17, all #761 release-lane + derives). issue65_fstring_mixed_holes respelled + green; err_ctor_payload_reuse pins the diagnostic.
sema: enum-constructor payloads mark their argument consumed (#764)
docs: handoff — #764 landed (isolated batch blessed); stage1 census f…
Sema/MIR: a place against a `&T` enum payload borrows — `Some(ctx)` f…
Sema/MIR: a place against a `&T` enum payload borrows — `Some(ctx)` f…
Sema/MIR: a place against a `&T` enum payload borrows — `Some(ctx)` f…
Sema/MIR: a place against a `&T` enum payload borrows — `Some(ctx)` f…
Sema/MIR: a place against a `&T` enum payload borrows — `Some(ctx)` f…
Spec-ruled fixes: Some(place) borrows for Option[&T], module globals …