Skip to main content

module_to_cached

Function module_to_cached 

Source
pub fn module_to_cached(
    module: &ModuleInfo,
    mtime_secs: u64,
    file_size: u64,
) -> CachedModule
Expand description

Convert a ModuleInfo to a CachedModule for storage.

mtime_secs and file_size come from std::fs::metadata() at parse time and enable fast cache validation on subsequent runs (skip file read when mtime+size match).