Stop the Layout claiming the hold runs only at render

This commit is contained in:
2026-09-21 18:44:33 +02:00
committed by Lillem4n
parent 6700a8ad9f
commit 88be57ea46
3 changed files with 6 additions and 7 deletions
+1 -1
View File
@@ -1328,7 +1328,7 @@ record.go records: Record, the JSON/CSV/SQL serializers, and their entry p
struct.go structs: FakeStruct, fake tags, and a field's Go type as its column's datatype
inline.go inline templates: Template, NewTemplate, FakeTemplate, IsTemplate, and their compile and link
template.go the {token} grammar: scanning, tokens, operands, validation, compiling a format
hold.go the hold at render: one draw per expansion for paths and operands, and the rows it pins
hold.go the hold: one draw per expansion for paths and operands, and the rows it pins
holdfence.go the load fences over the hold: the routes and spellings that read one held name two ways
draw.go one reference draw per render and group: the draw set a render reads its paths through
drawfence.go the load fences over reference draws: the drawGroup option, and the walk over a render's reads
+1 -2
View File
@@ -194,8 +194,7 @@ func TestReadmeTableExample(t *testing.T) {
}
}
// TestLayoutNamesEverySourceFile holds an added, renamed or split file to its Layout
// line, so the list a reader picks a file from stays the list on disk.
// TestLayoutNamesEverySourceFile holds an added, renamed or split file to its Layout line.
func TestLayoutNamesEverySourceFile(t *testing.T) {
src := readme(t)
i := strings.Index(src, "## Layout")
+4 -4
View File
@@ -26,12 +26,12 @@ This round, in order:
is the load path's spine, and no file name carries it.
- Name the `draw` stem apart: the free `pinned` in `holdfence.go` is not
`(*draws).pinned` in `hold.go`, `compileFormat` is a method on both `*template` and
`*table`, and
`draws`, `drawSet`, `drawScope`, `drawWalk`, `drawAt`, `drawKey`, `drawVisit` and
`drawRoute` no longer tell each other apart.
`*table`, and `draws`, `drawSet`, `drawScope`, `drawWalk`, `drawAt`, `drawKey`,
`drawVisit` and `drawRoute` no longer tell each other apart.
- Spell one fresh draw set one way: `newDrawSet` exists, and `render.go` and `draw.go`
hand-roll `drawSet{unnamed: draws{s: s}}` at three sites; name the lazy-map variant
if the difference is deliberate.
if the difference is deliberate, and say whether `draw.go`, 57 lines after the split,
still earns a file of its own.
- Run the package doc's Go example under test, as `readme_test.go` runs the README's
JSON blocks: `doc.go` and the README both print `Järvedsvägen 43\n891 77 Järved`
for seed 42, and nothing renders either, so a draw that moves leaves both false.