#semantic-analysis #validation #scope #sig #type-checking #grammar #inferred

leekscript-analysis

LeekScript semantic analysis: scope, validation, type checking

1 unstable release

new 0.1.0 Mar 8, 2026

#2929 in Rust patterns


Used in 3 crates

MIT/Apache

390KB
9K SLoC

Semantic analysis: scope building and validation.

Signature files (.sig): When .sig files are provided (e.g. stdlib), they are parsed with the signature grammar, then type expressions in each function/global declaration are turned into Type via parse_type_expr and seeded into the root scope. The type checker uses these for inference (e.g. call return types, global variable types). Use analyze_with_signatures(program_root, signature_roots) so that built-in names resolve and types are inferred from the .sig definitions.

Dependencies

~2.5MB
~45K SLoC