/** * Validation for `each="NAME"` on a ``. * * `each` walks a list, and there are exactly two ways to get it wrong: name * something that is not a sequence, or name a sequence that holds no list. * Both would render silently as zero lines — the child table would simply come * out empty, with no error anywhere, which is the failure mode this project * keeps refusing to ship. * Spec: docs/specs/2026-07-19-each-repeating-a-line-per-list-element.md §4 */ import { type Diagnostic } from '../errors/index.js'; import type { AttrContext, OpenCloseElementContext } from '../generated/TDCParser.js'; export interface EachContext { /** Sequence names declared in the env. */ readonly declared: readonly string[]; /** Of those, the ones whose generator repeats — walkable as a list. */ readonly repeating: readonly string[]; /** The pools — walkable record by record. */ readonly pools: readonly string[]; } export declare function checkLineEach(lineEl: OpenCloseElementContext, ctx: EachContext, diagnostics: Diagnostic[]): void; /** The same rule one level up: a conditional `` that holds a typed column. */ export declare function checkLineConditionalColumns(lineEl: OpenCloseElementContext, lineIf: AttrContext, diagnostics: Diagnostic[]): void; /** * The names an `each` line may read besides the run's own: the two old positional built-ins, the * walked name's positions (`Doctors._last`), and — walking a pool — every field of its records. * * The line's own `if=` gets the same set without the positions, which count the lines that `if=` * lets through and so cannot be what decides them. */ export declare function eachNames(each: string | undefined, declared: readonly string[], poolFields: ReadonlyMap, forIf: boolean): readonly string[]; //# sourceMappingURL=each.d.ts.map