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
Closure-adaptor run check reads a table column for a call outside its loop #8012
Gap.constant_table_column(fn_text, name) returns a constant-row table's column for name without checking that the asserted call sits inside that table's loop body. When the test's only binding of name is the loop pattern, a call after the loop that names name reads some other item, for example a module-level const x. The loop's rows are then credited as that call's values.
owner_pin/closure_adaptor.rs (RIPR-SPEC-0265 pinned_call_runs_closure, around argument_sequences) still calls constant_table_column. It can therefore credit a closure run from rows the asserted call never sees.
Repro shape (adaptor variant, not yet run):
#[allow(non_upper_case_globals)]const x:Option<i32> = None;#[test]fnt(){for(x, want)in[(Some(2),6)]{let _ = (x, want);}assert_eq!(f(x),0);// x is the const None; the closure never runs}
Fix. Switch the closure-adaptor lookup to constant_table_column_around, passing the assertion line's call offset, as short_circuit::call_offset does. Add an off-loop regression test.
Goal it hurts: trustworthy verdicts (false credit). Owner: the owner-pin / RIPR-SPEC-0265 lane.
Fixed by #8560 (squash 6fbe7b4). argument_sequences now uses constant_table_column_around with the call offset and refuses when the site is absent or ambiguous, so a table loop that does not contain the call no longer credits the pin. Tests: off-loop (fails on old code), in-loop positive, and twice-occurring site. Independent exact-head review: no blocking findings.
Activity
test(#8012): make off-loop table row a literal sequence and add dupli…
fix(rust): closure-adaptor table column requires the call inside its …
EffortlessSteven commentedon Oct 18, 2026
Fixed by #8560 (squash 6fbe7b4).
argument_sequencesnow usesconstant_table_column_aroundwith the call offset and refuses when the site is absent or ambiguous, so a table loop that does not contain the call no longer credits the pin. Tests: off-loop (fails on old code), in-loop positive, and twice-occurring site. Independent exact-head review: no blocking findings.Generated by Claude Code