Answer architecture round 1: share a step down's draw per draw group and pick, own descend's pins, name the spelling to write, and record the .. decision

This commit is contained in:
2026-10-05 00:05:58 +02:00
committed by Lillem4n
parent 4b5506d07b
commit 1ec2bee098
9 changed files with 92 additions and 41 deletions
+5 -3
View File
@@ -152,15 +152,17 @@ func (f *Generator) FakeRecord(path string) (*Record, error) {
}
// tableRecord walks a path's tail from a table to the table whose row is the record,
// pinning the rows it selects or draws.
// pinning in sc the rows it selects or draws.
func tableRecord(s *generatorState, t *table, tail []string, sc renderScope) (node, error) {
n, err := descend(s, t, tail, sc)
n, pins, err := descend(s, t, tail)
if err != nil {
return nil, err
}
group := sc.groupDraws()
group.pins = pins
switch n := n.(type) {
case *table:
n.drawIn(s, &sc.groupDraws().pins)
n.drawIn(s, &group.pins)
return n, nil
case *tableRow:
return n.t, nil