Skip to main content

check_program_collect

Function check_program_collect 

Source
pub fn check_program_collect(
    stmts: &[Stmt<'_>],
    interner: &Interner,
    registry: &TypeRegistry,
) -> (TypeEnv, Vec<IndexedTypeError>)
Expand description

Collect EVERY failing top-level statement instead of bailing at the first.

The environment after a failed statement is best-effort: inference simply continues with whatever bindings succeeded, so one bad Let does not cascade into errors on unrelated later statements. The strict fail-fast contract lives in check_program; compile paths keep using that.