Expand description
AST → IR lowering for top-level declarations.
Walks plsql_parser::Ast::root.declarations and produces a
LoweredFile containing one Declaration per recognized
AstDecl variant plus a Vec<Diagnostic> for unclassified rows
(R13 — typed uncertainty, never silent drops).
Pipeline:
- Iterate
ast.root.declarations. - For each variant emit a
Declarationwith the source name interned into the suppliedSymbolInterner. AstDecl::Unknownbecomes a typedparser-recovery-regiondiagnostic so the engine’sCompletenessReportreflects the unclassified region instead of dropping it.AstDecl::Ddlis currently informational — the rule engine that classifiesCREATE / ALTER / DROP / GRANTlives in the catalog + ChangeSet layers; here we record the verb in a diagnostic and let callers decide.
Structs§
- Lowered
File - Bundle of declarations + diagnostics produced by
lower_top_level.
Functions§
- lower_
top_ level - Lower every top-level
AstDeclinastto an IRDeclaration.