Say at checkNodeFences that its scope's cycles are refused first

This commit is contained in:
2026-09-30 21:32:49 +02:00
committed by Lillem4n
parent 4ed4b10fa2
commit e9b8216116
2 changed files with 3 additions and 4 deletions
+3 -1
View File
@@ -230,7 +230,9 @@ func (b binding) bind() error {
// checkNodeFences runs the per-node fences every binding needs over a scope, each
// over the whole scope before the next, so which of several broken nodes is reported
// does not depend on the walk. Its walks terminate only where nothing renders itself.
// does not depend on the walk. Its walks recurse unguarded, so the scope's cycles are
// refused first: a tree by checkNoCycles, and an inline node closes none, since nothing
// references it.
func checkNodeFences(s nodeScope) error {
mem := renderCounts{}
if err := s(func(path string, n node) error { return repeatCheck(path, n, mem) }); err != nil {
-3
View File
@@ -40,9 +40,6 @@ maintainer chose on 2026-09-30 to go on with the path steps regardless.
This round, in order:
- Say at `checkNodeFences` that its walks recurse unguarded, so a caller runs
`checkNoCycles` first: five seats reconstructed the order, and the inline binding runs
no cycle check.
- Give `tableSite` an `isFormat` beside `isCell`, so `renderRecord` and `traceRead` stop
comparing `row` with `formatRow` alone, which holds only because a template outside a
table has row 0: four seats found the invariant unstated.