Hacking on Gruel

Reference material for contributors working on the compiler itself. For language usage (rather than compiler internals), start with Learn Gruel.

Specification

Library crates

API documentation generated by rustdoc for each library crate in the workspace.

  • gruel-air — Typed IR produced by semantic analysis
  • gruel-builtins — Built-in type definitions (String, Vec, etc.)
  • gruel-cache — On-disk content-addressed cache for incremental compilation (ADR-0074)
  • gruel-cfg — Control flow graph construction and optimization
  • gruel-codegen-llvm — LLVM-based code generation for the Gruel compiler
  • gruel-compiler — Compiler pipeline orchestration
  • gruel-doc
  • gruel-fmt
  • gruel-intrinsics — Declarative registry of Gruel @intrinsics (names, signatures, runtime bindings, docs)
  • gruel-lexer — Tokenization of Gruel source code
  • gruel-lsp — Language Server Protocol implementation for Gruel (ADR-0091)
  • gruel-manifest — Tiny `gruel.json` package manifest loader (ADR-0092)
  • gruel-parser — AST construction from token stream
  • gruel-rir — Untyped IR (post-parse, pre-semantic analysis)
  • gruel-target — Target platform configuration
  • gruel-util — Shared utilities: source spans, error/diagnostic types, and IR operator enums