Skip to main content

qala_compiler/
lib.rs

1//! the Qala compiler and bytecode VM, as a single crate.
2//!
3//! the pipeline is lexer -> parser -> type and effect checker -> codegen -> VM.
4//! this file declares the modules in dependency order. the `wasm-bindgen`
5//! bridge that exposes the pipeline to JavaScript lives in `wasm.rs`.
6
7pub mod ast;
8pub mod diagnostics;
9pub mod effects;
10pub mod errors;
11pub mod lexer;
12pub mod parser;
13pub mod span;
14pub mod token;
15pub mod typechecker;
16pub mod typed_ast;
17pub mod types;
18// constant-pool value enum -- shared by chunk, codegen, vm
19pub mod value;
20// bytecode opcode enum -- consumed by chunk, codegen, optimizer, vm
21pub mod opcode;
22// instruction stream + constant pool + source map + disassembler.
23pub mod chunk;
24// typed AST -> bytecode; constant folding, DCE, defer compilation, comptime.
25pub mod codegen;
26// typed AST -> AArch64 assembly text; the CPSC 355 hosted-Linux dialect.
27pub mod arm64;
28// peephole optimizer -- single-pass bytecode rewrites.
29pub mod optimizer;
30// stack-based bytecode interpreter -- call frames, heap, single-step.
31pub mod vm;
32// native standard library -- the 15 built-in functions the VM dispatches.
33pub mod stdlib;
34// wasm-bindgen bridge -- the browser-facing Qala session API.
35pub mod wasm;