pub fn check_document_program(
program: LoadedProgram,
version: RustyfiVersion,
) -> Result<(), CompileError>Expand description
Typecheck a whole loader-resolved program, whichever of the three shapes it is, without evaluating it.
The dispatch mirrors the CLI’s own (rustyfi’s cmd_compile) exactly, and
for the same reasons: a V0_1 load is a module program; a V0_0 load that
carries a foreign V0_1 dependency is a cross-version splice; anything
else is the flat 0.0.6 prelude merge. version is the load’s own
rustyfi_loader::LoadOptions::version — Axis A, the entry’s generation —
not any individual file’s.