diff --git a/src/cargo/core/compiler/fingerprint.rs b/src/cargo/core/compiler/fingerprint.rs index 14f0dec42..d7636bf18 100644 --- a/src/cargo/core/compiler/fingerprint.rs +++ b/src/cargo/core/compiler/fingerprint.rs @@ -782,9 +782,6 @@ impl LocalFingerprint { } } -#[derive(Debug)] -struct MtimeSlot(Mutex>); - impl Fingerprint { fn new() -> Fingerprint { Fingerprint { @@ -1153,37 +1150,6 @@ impl hash::Hash for Fingerprint { } } -impl hash::Hash for MtimeSlot { - fn hash(&self, h: &mut H) { - self.0.lock().unwrap().hash(h) - } -} - -impl ser::Serialize for MtimeSlot { - fn serialize(&self, s: S) -> Result - where - S: ser::Serializer, - { - self.0 - .lock() - .unwrap() - .map(|ft| (ft.unix_seconds(), ft.nanoseconds())) - .serialize(s) - } -} - -impl<'de> de::Deserialize<'de> for MtimeSlot { - fn deserialize(d: D) -> Result - where - D: de::Deserializer<'de>, - { - let kind: Option<(i64, u32)> = de::Deserialize::deserialize(d)?; - Ok(MtimeSlot(Mutex::new( - kind.map(|(s, n)| FileTime::from_unix_time(s, n)), - ))) - } -} - impl DepFingerprint { fn new(cx: &mut Context<'_, '_>, parent: &Unit, dep: &UnitDep) -> CargoResult { let fingerprint = calculate(cx, &dep.unit)?;