Answer architecture round 1: calls carry no operands in the grammar, ParseCalc returns its operands, one empty-segment check, sorted token kinds, and file items 110 and 111

This commit is contained in:
2026-10-05 12:25:22 +02:00
committed by Lillem4n
parent 3479f9cf98
commit 6fd7da19e5
14 changed files with 103 additions and 103 deletions
+2 -2
View File
@@ -322,7 +322,7 @@ func (t *table) checkCells() error {
// compileRowFormat compiles the format a row renders through, over the columns as its
// fields.
func (t *table) compileRowFormat(format string) error {
toks, err := grammar.ParseFormat(format, builtinOperands)
toks, err := grammar.ParseFormat(format)
if err != nil {
return err
}
@@ -333,7 +333,7 @@ func (t *table) compileRowFormat(format string) error {
if tok.Kind != grammar.NameRead {
continue
}
for _, name := range tok.Names {
for _, name := range tok.Arms {
a := splitArm(name, nil)
if _, ok := t.col[a.head]; !ok && !grammar.IsRef(a.head) && a.head != "" {
return fmt.Errorf("format names no column %q of %s; the columns are %v", a.head, t.file, t.header)