docs: tuple syntax cutover — Tuple(...) type, .(...) value, channel-outside-Tuple failables
Rewrite specs.md tuple/failable/pack/UFCS/grammar sections to the new syntax, update readme.md, and refresh stale tuple references in example header comments. Also fixes two pre-existing doc inaccuracies surfaced in review: drop the value-discarding `;` in the tuple-return examples, and correct the §13 function-type grammar production (optional param list + optional trailing `!` channel). Optional semantics unchanged. current/CHECKPOINT-LANG.md logs the cutover.
This commit is contained in:
@@ -46,17 +46,17 @@ main :: () -> i32 {
|
||||
// ── GAPS (Feature 1 work — intentionally NOT exercised above) ──────
|
||||
//
|
||||
// G1. Tuple field projection across elements:
|
||||
// t := (Listenable.{value=1}, Listenable.{value=2});
|
||||
// v := t.value; // expected: (1, 2) — Decision 3 "tuple.field"
|
||||
// t := .(Listenable.{value=1}, Listenable.{value=2});
|
||||
// v := t.value; // expected: .(1, 2) — Decision 3 "tuple.field"
|
||||
// Today: `error: field 'value' not found on type 'tuple'`.
|
||||
// Needed by canonical `self.sources.value`.
|
||||
//
|
||||
// G2. Tuple spread into call args:
|
||||
// p := (10, 20);
|
||||
// p := .(10, 20);
|
||||
// add(..p); // expected: add(10, 20) — Decision 3 "..tuple"
|
||||
// Today: lowers to one `undef` arg → LLVM arity verification failure.
|
||||
// Needed by canonical `mapper(..sources.value)` and `(..sources)`.
|
||||
// Needed by canonical `mapper(..sources.value)` and `.(..sources)`.
|
||||
//
|
||||
// Both are already scheduled: parsing in Phase 1.2 (PackExpansion node covers
|
||||
// `(..pack)` / `..pack.field`), sema in Phase 2.3 ("tuple-spread parallels").
|
||||
// `.(..pack)` / `..pack.field`), sema in Phase 2.3 ("tuple-spread parallels").
|
||||
// No separate Feature 1.5 needed — see Step 0.4 triage in CHECKPOINT-LANG.md.
|
||||
|
||||
Reference in New Issue
Block a user