commit 5097ba0a660e13247abb1fa0c29c2d56aa6e34a1
parent 3e69628b753954fae92418a20c64a834148d0b6c
Author: Jack Mordaunt <jackmordaunt.dev@gmail.com>
Date: Sun, 20 Sep 2026 08:29:25 -0300
walk: drop the allocator nobody reads
Config carried an allocator field that `scan` never consulted; it took
context.allocator and passed that everywhere. Offering a knob that does nothing
is worse than not offering one.
It cannot be honoured as things stand either: the discard callback that frees
unwalked directories takes no state, so it can only reach the context allocator.
Wiring the field up would strand those paths again.
Diffstat:
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/walk/walk.odin b/walk/walk.odin
@@ -19,9 +19,8 @@ import "../flow"
import "../scan"
Config :: struct {
- workers: int, // 0 selects DEFAULT_WORKERS
- follow: bool, // descend through symlinks and junctions; loops are not detected
- allocator: mem.Allocator,
+ workers: int, // 0 selects DEFAULT_WORKERS
+ follow: bool, // descend through symlinks and junctions; loops are not detected
}
// Directory reads are latency bound and hold no core while they wait, so more