# Handoff — 2026-09-09 — Turbo MoonBit, first build ## State The editor is complete and green. `make check` passes, the quality gate passes, the documentation is written in both languages, and the binary has been driven through a pty. Nothing is in flight. The working tree is **uncommitted**. Everything described here exists on disk on `main`, at `a1558e2` (the initial commit), and has not been staged. That was deliberate — no commit was asked for. ## Added after the first pass `demos/` — three MoonBit projects (`hello`, `shapes`, `syntax-tour`) with a README. All three `moon check` clean, are unchanged by `moon fmt`, and run; `shapes` has five tests. **Building them is what found three things the Go suite could not**: `derive(Show)` and the functional `loop` form are both deprecated (the starter snippets file used both — fixed), and `typealias` is not accepted at top level by this compiler although the grammar lists it as a keyword. Opening `syntax-tour/tour.mbt` in a pty also found a scanner boundary the docs had described too loosely: a string nested inside an interpolation ends the outer literal. The reference and the explanation now state it exactly, a test pins it, and the demo keeps the offending line with a comment. ## What was touched outside this repository Two sibling repositories were edited, and both need their own commit: - **turbo-core** — `README.md`, `docs/{en,fr}/README.md`, `docs/{en,fr}/how-to/test-without-publishing.md`, `profile/profile.go`'s package comment, and `.memory/summary.md`: all now count four editors. Its `.go` strings were swept for hardcoded language names and **no code change was needed**, which is the strongest evidence yet that the seam holds. - **turbo-python** — a real defect, found because this editor was adapted from it. Its docs claimed the Python menu answers to `Alt-T`; it answers to `Alt-P`. `Alt-T` is Turbo Rust's, inherited through a mechanical substitution that only looked at identifiers. Fixed in eight places across both languages, along with "all three editors" → four in its architecture explanation. **That repository's `.memory/` has not been updated**, and should get a history entry saying so. ## Next steps 1. **Commit.** This repository, turbo-core and turbo-python each want one. 2. **Tag a release.** `release.env` currently says `TAG="v0.1.1"`, copied from turbo-python; the first tag here should be `v0.1.0`. `01-release.tag.sh` runs `make check` and refuses a live `replace`, so it should go through as it stands. 3. **Read the two boundaries in `summary.md`** before promising anything about diagnostics or about labels in `turbo-classic`. ## Open questions / blockers - **Should turbo-core send `workspace/didChangeWatchedFiles`?** It is the fix for "moon-lsp never diagnoses a file created after it started", it would help every editor in the family, and it is a library change with its own `/methodical-dev` cycle. Not started. - **Should `turbo-classic` give `syntax.attribute` its own colour?** It is currently the same yellow as `syntax.identifier`, so a MoonBit label or attribute is invisible as such in that one theme — and Turbo Rust's `#[derive]` has the same problem. Also turbo-core's decision. - **Nothing here has run on macOS or Windows.** The user's machine is macOS; the binary built in this sandbox is an ELF they cannot run. ## Watch out for - **Do not use a shell `cp file /tmp/x; …; cp /tmp/x file` round trip to back a file up before mutating it.** Doing that during mutation testing silently left three source files NUL-padded, and the symptom was `unexpected NUL in input` from the compiler rather than anything pointing at the backup. Mutate in-process instead: read the file into a Python string, write the mutation, write the original string back. `/tmp/falsify*.py` do it that way and are safe to re-run. - **`gofmt` rewrites a bare run of three apostrophes in a doc comment into typographic quotes.** `templates.go` says "three apostrophes" in words for that reason; do not helpfully replace it with the characters. - **`moon-lsp` with no argument prints its usage and exits.** The `--stdio` in `ServerArgs()` is load-bearing, and dropping it looks like a server that died at start-up. - **A fixture project for the language-server tests must compile.** `brokenProject` exists as a *second* fixture rather than as an extra file in the first, because a package holding an error makes every other answer from the server worthless — the completion test would then be measuring a broken build. - **The `-short` flag skips every moon-lsp test.** A green `go test -short ./...` proves nothing about the server. - **The demos are not checked by anything automatic.** They were built, run and formatted by hand. A future MoonBit release could deprecate something in them and nothing would say so — re-run `moon check` in each before a release, or wire it into `make check` if the toolchain can be assumed present. - **`docs/*/reference/languages.md` is read by a test.** `TestEveryKeywordTheReferenceListsIsAKeyword` parses the keyword row out of the English page, so reformatting that table breaks the test rather than the docs.