Make great documentation goal 1.2, and plan the README's reorganisation and the nested-template gaps #33

Open
lilleman wants to merge 966 commits from worktree-todo-relative-dates-exact-counts into main
2 changed files with 6 additions and 10 deletions
Showing only changes of commit 2254b33f0e - Show all commits
+5 -6
View File
@@ -196,14 +196,13 @@ func inlineScope(n node, label string) nodeScope {
return func(fn func(path string, m node) error) error { return eachNode(n, label, fn) }
}
// binding is one entry point's nodes on their way through bind, the load pipeline New,
// NewTemplate and FakeStruct share; its fields are where they differ.
// binding is one scope's way through bind, the one load pipeline; its fields are where
// scopes differ.
type binding struct {
scope nodeScope
link func() error
// A loaded tree's cycle fence; an inline node's refusal of a drawGroup at its root.
scope nodeScope
link func() error
referenceFence func() error
// checkField proves a struct's columns instead.
// Set by a caller that proves the columns against their Go types itself.
typedByGo bool
}
+1 -4
View File
@@ -56,10 +56,7 @@ tags and any other caller read one.
## An inline template skips the cycle fence
`New` proves the loaded tree acyclic, an inline node is a finite tree of its own, and
nothing in the tree can reference it, so no render of it reaches itself. Every other
fence runs over both, from one `binding.bind`, except that struct tags leave column
agreement to their Go types, and an inline node refuses a `drawGroup` at its root,
which nothing can name.
nothing in the tree can reference it, so no render of it reaches itself.
## An inline template that does not compile is misuse (exit 2), including a reference that resolves to nothing