pub struct DiscoveredInputs {
pub inputs: Vec<ActionInput>,
pub environment: BTreeMap<String, Option<String>>,
/* private fields */
}Expand description
A complete, content-addressed compiler input manifest.
Fields§
§inputs: Vec<ActionInput>Content-addressed compiler input files.
environment: BTreeMap<String, Option<String>>Environment inputs captured from dep-info.
Implementations§
Source§impl DiscoveredInputs
impl DiscoveredInputs
Sourcepub fn verify_not_modified_since(
&self,
started_at: SystemTime,
) -> Result<(), BypassReason>
pub fn verify_not_modified_since( &self, started_at: SystemTime, ) -> Result<(), BypassReason>
Reject inputs whose modification time overlaps the compiler invocation.
Input contents are first hashed after rustc reports their paths. This
timestamp barrier prevents a post-compile write from being mistaken for
the contents that produced the artifact. verify closes the remaining
race after hashing.
Sourcepub fn verify(&self) -> Result<(), BypassReason>
pub fn verify(&self) -> Result<(), BypassReason>
Rehash every discovered file after compilation and before publication. This closes the discovery/compile race by degrading changed inputs to a cache miss rather than storing outputs beneath a stale action key.
Sourcepub fn apply_to(self, context: &mut ActionContext) -> Result<(), BypassReason>
pub fn apply_to(self, context: &mut ActionContext) -> Result<(), BypassReason>
Merge the manifest into an action context after verifying that both use the same compiler working directory.
Trait Implementations§
Source§impl Clone for DiscoveredInputs
impl Clone for DiscoveredInputs
Source§fn clone(&self) -> DiscoveredInputs
fn clone(&self) -> DiscoveredInputs
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more