Expand description
Bynk’s TypeScript emission, plus the per-unit build sequencing that drives
it — the layer above bynk-project (discovery, the dependency graph) and
bynk-check (all semantic checking, R3.5).
project owns compile_project/run_checks: the two-pass sequence over
a project’s units — discover and parse (bynk-project), then resolve,
type-check (bynk-check) and emit each unit with full visibility of what
it uses/consumes. emitter lowers a checked program to TypeScript.
Input: a project tree (or an in-memory overlay). Output: TypeScript files
plus diagnostics — this crate originates none of its own (P5.5,
design/tracks/semantics-in-the-checker.md §3.5, R10.1).
Extracted from bynkc as slice 4 of the crate-decomposition track over
bynk-syntax + bynk-check. Behaviour is unchanged; bynkc depends on this
crate and re-exports its modules so its public API (compile_project,
ProjectOutput, …) and the binary are untouched.
Modules§
- emitter
- TypeScript emission (spec §7, v0.1 §6, v0.2 §6).
- project
- Multi-file project compilation (v0.3 §3.2 and §3.3, v0.4 §3.5).
Structs§
- Compiled
- A single-file compile that also returns the non-failing warnings produced on
success — what a CLI prints (v0.89, ADR 0117).
compileis the warning-discarding convenience over this.
Constants§
- NODE_
MAJOR_ FLOOR - Minimum supported Node.js major version for the
nodeplatform binding and for running Bynk’s emitted TypeScript.
Functions§
- compile
- Compile a single Bynk source string to a TypeScript string.
- compile_
with_ warnings - The warning-preserving single-file compile behind
compile. SeeCompiled.