Summary
A closure defined inside another closure's body that widens @Nat into an @Int return is runtime-guarded by codegen (_compile_lifted_closure lifts and guards it) but not obligated by the verifier — the verifier's AnonFn widening handler is deliberately shallow: it does not recurse into a closure body, because translating there against the outer slot environment could mis-resolve a closure parameter and prove a false Tier-1.
Consequence: codegen over-guards (sound — an extra runtime trap on a real widening, never a false proof), but vera verify under-reports: the obligation stream carries no entry for the nested closure's widening, so the summary's Tier-3 count omits a runtime check that codegen actually emits, and the strict verifier↔codegen differential does not hold for the nested shape.
A reporting-completeness limitation, not a soundness hole — same family as #779 (obligation walkers stopping at fresh-scope bodies: closures / quantifiers / handler clauses).
Found during the #820 per-component metadata work (PR pending), which added the single-level closure argument/return/capture obligations and guards; the nested case is the residual.
Summary
A closure defined inside another closure's body that widens
@Natinto an@Intreturn is runtime-guarded by codegen (_compile_lifted_closurelifts and guards it) but not obligated by the verifier — the verifier'sAnonFnwidening handler is deliberately shallow: it does not recurse into a closure body, because translating there against the outer slot environment could mis-resolve a closure parameter and prove a false Tier-1.Consequence: codegen over-guards (sound — an extra runtime trap on a real widening, never a false proof), but
vera verifyunder-reports: the obligation stream carries no entry for the nested closure's widening, so the summary's Tier-3 count omits a runtime check that codegen actually emits, and the strict verifier↔codegen differential does not hold for the nested shape.A reporting-completeness limitation, not a soundness hole — same family as #779 (obligation walkers stopping at fresh-scope bodies: closures / quantifiers / handler clauses).
Found during the #820 per-component metadata work (PR pending), which added the single-level closure argument/return/capture obligations and guards; the nested case is the residual.