Answer architecture round 2: one folder walk and one sorted-keys helper, REGENERATE for the index, and the held decisions naming the items that end them

This commit is contained in:
2026-10-03 17:38:26 +02:00
committed by Lillem4n
parent c3b462ec0a
commit 3bb8628e39
9 changed files with 51 additions and 61 deletions
+1 -6
View File
@@ -406,12 +406,7 @@ func readOptions(m map[string]any, pos position) (templateOptions, error) {
// compileFields compiles every non-option key of a template object.
func compileFields(m map[string]any, pos position) (map[string]node, error) {
fields := make(map[string]node, len(m))
keys := make([]string, 0, len(m))
for k := range m {
keys = append(keys, k)
}
sort.Strings(keys)
for _, k := range keys {
for _, k := range sortedNames(m) {
if isOption(k) {
continue
}