pub fn cache_dir(
class_name: &str,
csharp_source: &str,
build_raw: &str,
run_raw: &str,
references: &[PathBuf],
target_framework: &str,
) -> PathBufExpand description
Compute the deterministic cache-dir path used to store compiled C# assemblies.
The path is <base_cache_dir>/<class_name>_<hex_hash>/ where hex_hash is a
64-bit hash of:
csharp_source— the complete C# source textexpand_dotnet_args(build_raw)— shell-expanded build argsstd::env::current_dir()— the process working directory at call timerun_raw— hashed as a raw stringreferences— the list of reference DLL pathstarget_framework— the TFM moniker (e.g."net8.0")- maximum mtime (nanoseconds since Unix epoch) of any C#/dotnet-related file
(
.cs,.dll,.nupkg,.zip) found under directories inreferences, or the mtime of individual files listed there;Noneis hashed when no such paths are present
The base directory is resolved by base_cache_dir.