discovery: fix ireturn on the shared cache reader
main·
Commit

CI's golangci-lint flagged ireturn on the generic readCacheFile, which
returned its type parameter T. (Locally the nolint directive that
silenced it kept getting stripped by golangci-lint run --fix's
nolintlint autofix, so it only surfaced in CI.)
Replace it with loadCacheFile(path, *T, newEmpty) error: it fills a destination pointer and returns error, which ireturn allows, while still sharing the read/unmarshal/corrupt-reset logic across both caches.
Co-Authored-By: Claude Opus 4.8 (1M context) noreply@anthropic.com Entire-Checkpoint: 6d6f3baefcd9
Checkpoints
Checkpoint 1