pub fn parse_all_files_cached(
sources: &[SourceFile<'_>],
preview_features: &PreviewFeatures,
cache: &CacheStore,
build_fp: &CacheKey,
) -> MultiErrorResult<(ParsedProgram, ParseCacheStats)>Expand description
Run the parse pipeline with cache lookup/store enabled.
Behavior:
- For each
SourceFile, computeparse_keyand probe the cache. - On hit: deserialize
CachedParseOutput, re-intern its snapshot into the build’s sharedThreadedRodeo, and walk the AST to substitute Spurs via the remap. Skip lex+parse for that file. - On miss: lex+parse into a fresh per-file interner, snapshot it, store the cached output, then merge into the build interner the same way as a hit (ensuring the merge path is exercised on every build, not just hits).
Returns the parsed program plus per-stage cache stats.