Skip to content
Beskid The Beskid Book

Beskid

Jump to a Beskid service

Beskid

Jump to a Beskid service

15. Mods: plugins with consequences

Compiler mods—Collector, Generator, Analyzer, Rewriter—and the AOT-only host pipeline.

Mods: plugins with consequences

Mods are plugins with consequences: they mutate the compile graph, re-parse generated AST, and can fail closed with E18xx diagnostics before your app code runs. The compiler itself stays Rust; your extension is Beskid type: Mod plus AOT artifacts.

Normative Beskid surface: Compiler Mod SDK. Host law: Compiler mods and Mod host bridge.

| Section | Topic | | --- | --- | | What is a mod | Project kind, discovery, boundaries. | | Mod SDK | Contracts, Syntax mirror, query DSL. | | Generator, Analyzer, Rewriter | Roles and ordering. | | beskid mod CLI | Build and wire mod packages. | | Pipeline phases | collect → generate → analyze → rewrite. |

What is a mod

Return to book reference for CLI details, or read Implementation map when filing spec+crate changes.