fn is_rerun_needed(&self, status: &mut dyn StatusBackend) -> Option<RerunReason> {
        // TODO: we should probably wire up diagnostics since I expect this
        // stuff could get finicky and we're going to want to be able to
        // figure out why rerun detection is breaking.

        for (name, info) in &self.events.0 {
            if info.access_pattern == AccessPattern::ReadThenWritten {
                let file_changed = match (&info.read_digest, &info.write_digest) {
                    (&Some(ref d1), &Some(ref d2)) => d1 != d2,
                    (&None, &Some(_)) => true,
                    (_, _) => {
                        // Other cases shouldn't happen.
                        tt_warning!(
                            status,
                            "internal consistency problem when checking if {} changed",
                            name.to_string_lossy()
                        );
                        true
                    }
                };

                if file_changed {
                    return Some(RerunReason::FileChange(name.to_string_lossy().into_owned()));
                }
            }
        }

        None
    }
/// Assess whether we need to rerun an engine. This is the case if there
/// was a file that the engine read and then rewrote, and the rewritten
/// version is different than the version that it read in.
Assess whether we need to rerun an engine. This is the case if there
was a file that the engine read and then rewrote, and the rewritten
version is different than the version that it read in.
Assess whether we need to rerun an engine . This is the case if there was a file that the engine read and then rewrote and the rewritten version is different than the version that it read in .
fn is_rerun_needed(&self, status: &mut dyn StatusBackend) -> Option<RerunReason> {
        // TODO: we should probably wire up diagnostics since I expect this
        // stuff could get finicky and we're going to want to be able to
        // figure out why rerun detection is breaking.
        for (name, info) in &self.events.0 {
            if info.access_pattern == AccessPattern::ReadThenWritten {
                let file_changed = match (&info.read_digest, &info.write_digest) {
                    (&Some(ref d1), &Some(ref d2)) => d1 != d2,
                    (&None, &Some(_)) => true,
                    (_, _) => {
                        // Other cases shouldn't happen.
                        tt_warning!(
                            status,
                            "internal consistency problem when checking if {} changed",
                            name.to_string_lossy()
                        );
                        true
                    }
                };
                if file_changed {
                    return Some(RerunReason::FileChange(name.to_string_lossy().into_owned()));
                }
            }
        }
        None
    }
fn is_rerun_needed ( & self , status : & mut dyn StatusBackend ) -> Option < RerunReason > { // TODO: we should probably wire up diagnostics since I expect this // stuff could get finicky and we're going to want to be able to // figure out why rerun detection is breaking. for ( name , info ) in & self . events . 0 { if info . access_pattern == AccessPattern :: ReadThenWritten { let file_changed = match ( & info . read_digest , & info . write_digest ) { ( & Some ( ref d1 ) , & Some ( ref d2 ) ) => d1 != d2 , ( & None , & Some ( _ ) ) => true , ( _ , _ ) => { // Other cases shouldn't happen. tt_warning ! ( status " " name to_string_lossy ( ) ) ; true } } ; if file_changed { return Some ( RerunReason :: FileChange ( name . to_string_lossy ( ) . into_owned ( ) ) ) ; } } } None }
Assess whether we need to rerun an engine.
Assess whether we need to rerun an engine .
&self
status
&mut dyn StatusBackend