Files
AILang/docs/journals/2026-05-13-iter-form-a.0.md
T
Brummel aabcadca5f iter form-a.0: prelude pilot — examples/prelude.ail rendered
First iteration of the form-a-default-authoring milestone. Mechanical:
one `ail render examples/prelude.ail.json > examples/prelude.ail`
captures the canonical Form-A projection (116 lines / 6386 bytes).
No source-code edits, no test edits.

The two auto-discovering roundtrip tests in
crates/ailang-surface/tests/round_trip.rs pick up the new fixture
via read_dir without test changes and both pass:
- every_ail_fixture_matches_its_json_counterpart — the .ail parses
  to canonical bytes byte-equal to prelude.ail.json (gate test).
- parse_then_print_then_parse_is_idempotent_on_every_ail_fixture —
  the Form-A printer is idempotent over prelude.

cargo test --workspace green at 558 tests (identical to pre-iter
baseline; audit-24 / iter-24.tidy lineage).

prelude.ail.json retained per spec §A2 — this is the singular
dual-form iter; iter 1 deletes it alongside the bulk test-infra
refactor.

Zero re-loops, zero review-phase repairs. Recon predictions matched
reality exactly (116 lines, 6386 bytes, `(module prelude` header,
558-test baseline). Strong signal that the iter-1+ bulk migration
mechanism is sound.
2026-05-13 09:59:30 +02:00

3.4 KiB

Iter form-a.0 — Prelude Pilot

Date: 2026-05-13 Parent spec: docs/specs/2026-05-13-form-a-default-authoring.md Parent plan: docs/plans/2026-05-13-iter-form-a.0.md Started from: 4c2a3c5d08

Outcome

examples/prelude.ail rendered from examples/prelude.ail.json via ail render (116 lines / 6386 bytes — exact recon match). The two auto-discovering roundtrip tests in crates/ailang-surface/tests/round_trip.rs both pass on the new fixture without test-code changes:

  • every_ail_fixture_matches_its_json_counterpart — green; the prelude.ail parses to canonical bytes byte-equal to prelude.ail.json.
  • parse_then_print_then_parse_is_idempotent_on_every_ail_fixture — green; the Form-A printer is idempotent over prelude.

prelude.ail.json is retained on disk per spec §A2; iter 1 deletes it alongside the bulk test-infrastructure refactor. This is the only iteration in the milestone where a fixture is dual-form.

Why this iter is the pilot

Spec §A2 names prelude as the pilot because it exercises the widest cross-section of language features in a single file: typeclasses with superclasses (Ord extends Eq), polymorphic free functions with constraints (forall<a> where Show a fn print), IO-effect signatures, primitive ctor patterns, and the loader's auto-injection path. A green roundtrip on prelude is strong evidence the bulk migration in iter 1+ will not surface render or parse bugs.

Verifications run

  • cargo run -q --bin ail -- render examples/prelude.ail.json > examples/prelude.ail — exit 0
  • wc -lc examples/prelude.ail116 6386 (exact recon prediction)
  • head -n 5 examples/prelude.ail — first line (module prelude, second (data Ordering (exact recon prediction)
  • cargo test -p ailang-surface --test round_trip every_ail_fixture_matches_its_json_counterpart — PASS (1/1)
  • cargo test -p ailang-surface --test round_trip parse_then_print_then_parse_is_idempotent_on_every_ail_fixture — PASS (1/1)
  • cargo test --workspace — PASS, 558 tests green, identical to pre-iter baseline (audit-24 / iter-24.tidy lineage).

Scope NOT touched

Per spec §"Iteration scope": no test-infrastructure changes, no CLAUDE.md / DESIGN.md edits, no deletion of prelude.ail.json, no migration script yet. Those land in iter 1.

INDEX append — Boss-side

Plan Task 2 Step 2 asks for an INDEX.md append. Per the ailang-implement-orchestrator Iron Law, docs/journals/INDEX.md is Boss-only. The orchestrator does not touch it. The Boss appends the line at commit time. Suggested INDEX line (from the plan verbatim, byte/line counts confirmed by Task 1 Step 2):

- 2026-05-13 — iter form-a.0: prelude pilot for Form-A-as-default-authoring milestone — examples/prelude.ail rendered (116 lines / 6386 bytes) via `ail render`; two auto-discovering roundtrip tests (every_ail_fixture_matches_its_json_counterpart + parse_then_print_then_parse_is_idempotent_on_every_ail_fixture) green on the new fixture without test-code changes; prelude.ail.json retained per spec §A2 (singular dual-form iter, deletion lands iter 1 with bulk test-infra refactor); cargo test --workspace green → 2026-05-13-iter-form-a.0.md

Files touched

  • examples/prelude.ail (new, ~6386 bytes / 116 lines)
  • docs/journals/2026-05-13-iter-form-a.0.md (this file)
  • bench/orchestrator-stats/2026-05-13-iter-form-a.0.json (stats)

Stats

bench/orchestrator-stats/2026-05-13-iter-form-a.0.json