pub fn check_scopes(
stmts: &[Stmt<'_>],
scope: &ScopeInfo,
interner: &Interner,
) -> Result<(), String>Expand description
Enforce per-file scoping over the assembled program: a reference to a name that is another user module’s export, from a file that neither defines nor imports it, is a hard error (no transitive leakage). Builtins, stdlib, and a file’s own/imported names are always fine, so a valid program never trips.