Skip to main content

Module parser

Module parser 

Source

Re-exports§

pub use ast::*;

Modules§

ast

Structs§

ParseErrorWithSpan
A parse failure paired with the span of the token where it was detected.

Enums§

EntrypointResolution
Result of resolving a CLI entrypoint name against a set of modules.

Functions§

find_cross_module_func_collisions
Same as find_cross_module_sub_collisions, for bare Function names (a separate namespace from Subs, same as within a single module today).
find_cross_module_sub_collisions
Bare Sub names that appear in 2+ modules, mapped to the list of module names that declare them — the flat cross-module namespace can’t disambiguate these (own-module-first/Private VBA scoping isn’t modeled), so callers should reject the run rather than pick one silently.
parse
parse_with_span
Like parse, but on failure also reports where in the source the parser gave up. Existing callers should keep using parse — this is additive, for the --json CLI contract’s location reporting.
resolve_entrypoint
Resolve a bare (MySub) or qualified (Module1.MySub) entrypoint name against modules. Callers are expected to have already rejected cross-module bare-name collisions (see find_cross_module_sub_collisions) before calling this — a collision-free namespace means this only ever has two outcomes, no “ambiguous” case.