- source bundle: a /docs directory with QUICK.md (Quick Reference plus a
where-to-read table), language/*.md, diagnostics/errors.md and the AIR
bundle only under air/; built from docs/agent/source-bundle.txt
(> output files, @manifest includes) by zig build agent-reference
- Quick Reference examples are checked: every aji block must be an
excerpt of a conformance program in tests/conformance/source/quickref
(zig build test fails otherwise); QR fixes found by the check
(mut d = data, region not auto-borrowed, statement/borrow blocks that
could not verify, io_error match)
- frontend: task.*/channel.*/mutex.* are not-yet-implemented, not E7006
- aji lower --stats: mechanical_air_eliminated_raw and _normalized (each
byte-string materialization counted as one constant; spec 15 §11)
- harness: profile aji_source (doc_groups), per-file and per-group docs
metrics on distinctive lines, profile columns (tool calls, lowered AIR
raw/normalized, docs files read, IR-form and type-mismatch counts),
dev-echo aji_source variant, scripted run and test, source token report
- plan: P6A-8 done, P6A-9 criteria; Q-021/Q-022 resolved; unsafe block
deferred
revision 2 per owner review: reserved-feature dependencies may change
until publication (general rule, DD-014); task.join.cancel returns the
handle on cancelled with loans still LOANED; channel.sender.dup from
ref<sender<T>> (MPSC, receiver_dup reserved); task.wait required by
every suspending operation, task.join included, only in modules
declaring cancellation; sent values and handles come back as block
parameters on closed/cancelled edges; explicit channel states
spec 04 §37-§41 and pointers in §11-§16, §35, §36; spec 05 §9, 07
§8.11, 07a, 08 §14, 11 §6-§7; features cancellation, channels, sync
published (implementation pending); rwlock, channel_transfer,
receiver_dup, guard_transfer reserved; effect task.wait; E4304, E4305;
Q-013 resolved; bundle +15.8 % tokens (recorded)
features cancellation, channels, sync; bounded/rendezvous channels with
separate linear endpoints and a drain-then-close receiver protocol;
waiting-operation rule with ok/closed/cancelled edges; shields with
innermost-first nesting (E4305); mutex with function-bound guard and the
no-wait-while-locked rule (E4304); select over channel operations with
seeded choice among ready arms and per-edge ownership (Q-013); rwlock,
channel_transfer, guard_transfer reserved; owner decisions D1-D3
- air: cap<K> and built-in enums (cap_error) as types; enum.switch over
built-in enums; cap.narrow terminator with ok/err targets; intrinsic
syntax (registry still empty: E0004); registries for effects,
capability kinds and built-in enums, synced with reference docs
- verifier: effect stage (E3101, flat, direct callees); cap.narrow form
check (E3202) and ok/err parameter rules (E5002, E1001); capabilities
are copyable, not zeroable, not comparable; sizes cap 8, built-in tag
- interp: host authority table; @main instantiation from grants by
parameter name with not_instantiated reasons; capabilities render as
opaque
- CLI: --grant P=KIND[:SCOPE], exit code 6; runner: grant: and
not_instantiated: headers, pending only for unsupported features
- conformance: 18 Phase 2 tests; 4000 mutants without a crash
- spec 08 §7.1: platform-independent accounted size table shared by
max_value_size and max_local_frame; enum tag is the smallest of
1/2/4/8 bytes; borrows 8, slices 16; checked arithmetic, overflow is
E5101 with found = "overflow"
- every materializable type in a module must be at most 1 MiB,
checked before functions are verified; each oversized type reported
once
- E5101 fields no longer truncate huge sizes
- conformance: frame_too_large, value_too_large, size_overflow
- Q-020 resolved; Phase 1 closed
- all Phase 1 tasks done, exit criterion met
- README and architecture reflect the implemented modules
- open question Q-020: size bound for SSA array values
- RFC 0005 Accepted (revision 2)
- spec 07 §8.8 types and syntax; spec 07a contracts for features
ownership and arrays; spec 08 §11-§14 borrows, facts, initialization,
stage order; spec 03 frame storage, second-class borrows, static
region generations
- grammar: from-returns, multi-result, new types and opcodes
- feature registry: ownership and arrays published; heap added and
regions moved to Phase 2; borrow_joins reserved and unscheduled
- codes E2105-E2108, T0008
- Q-009, Q-010 resolved; Phase 1 and Phase 2 plans updated; Own test
moved to phase 2
- reference/air-features.md: normative feature registry (arrays,
atomics, capabilities, channels, effects, islands, ownership, regions,
sync, tasks; all reserved), dependency closures, reasons for E0006
- spec 07 §8.1/§8.5/§8.7: features are mandatory, validated before the
body, full dependency closure declared, sorted canonically; every
extension belongs to a feature; published feature semantics immutable
- spec 05 §8: features vs effects vs capabilities
- src/air/features.zig: registry, validation, sync test with the docs
- parser validates features first; E0006 carries `reason`
- `aji features` prints supported AIR format, language and features
- conformance: unknown, reserved and duplicate feature tests
- plan: feature publication tasks in phases 1-5
Owner decisions after the Phase 0 review:
- precedence: docs/spec/ is the single normative source; RFCs are
decision records whose accepted rules are integrated into the spec in
the same change (AGENTS.md, docs/README.md, rfcs/README.md, DD-011)
- RFC 0004 Accepted (scope: AIR format 0, language 0.1)
- AIR format 0 frozen as the semantic baseline; spec 07 §8.7 defines the
only permitted additive changes, everything else needs `air 1` (DD-012)
- Q-019 resolved: deterministic instruction fuel (spec 11 §7). Outcome
`limit_exceeded` is a runner outcome, not a trap; `aji run --fuel N`,
exit code 5; conformance runs always use fuel (default 1 000 000,
`fuel:` header); fuel/schedule budget/quantum kept separate for P3
(DD-013)
- all Phase 0 tasks done; exit criterion met (41 conformance tests,
run records compared across two runs)
- RFC 0004 Amendment 1 documents format-0 additions; status stays
Proposed pending owner acceptance
- open question Q-019: non-terminating programs in test tooling
- README/CONTRIBUTING: current state and `aji run`
- src/interp/machine.zig: format-0 interpreter on the air64 target;
checked/wrapping arithmetic, shifts, casts, aggregates, calls with a
1024-frame limit, traps as records with T0xxx codes
- aji run: prints one JSON run record; exit code 4 on trap
- conformance runner: `expect: run` with `result:`/`trap:`, every run
executed twice and compared byte-for-byte; header keys must be single
lowercase words
- Phase 0 corpus: 3 accept, 19 reject, 15 run tests (41 total)
- text AIR format 0: grammar (reference/air-text.ebnf) and module,
block, SSA, type and canonical-form rules (spec 07 §8)
- instruction contracts for format 0 (new spec 07a)
- traps: stable T0xxx codes and trap records (spec 01 §6)
- integer edge cases and explicit casts (spec 02 §2.1)
- fixed verifier resource limits (spec 08 §7)
- target description with pointer_bits (spec 09 §9)
- new codes E0001-E0006, E1003, T0001-T0007
- resolves Q-001, Q-003..Q-008, Q-018; Q-002 resolved for format 0
- docs/roadmap/ -> docs/plan/ (implementation-plan.md becomes plan/README.md)
- docs/reference/design-decisions.md -> docs/design/decisions.md (+ DD-008..010)
- SPEC.md and docs/spec/INDEX.md merged into docs/spec/README.md
- new docs/design/open-questions.md: spec gaps found so far (Q-001..Q-018)
- new docs/dev/architecture.md and docs/dev/testing.md
- docs/README.md: layout, precedence, where new documents go
- update links in README, AGENTS, CONTRIBUTING, sources and test docs