diff --git a/Cargo.lock b/Cargo.lock index 4342c17a..118d31ed 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -147,7 +147,6 @@ dependencies = [ "ansi_term 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)", "atty 0.2.14 (registry+https://github.com/rust-lang/crates.io-index)", "bitflags 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)", - "strsim 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)", "textwrap 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)", "unicode-width 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", "vec_map 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)", @@ -615,11 +614,6 @@ dependencies = [ "unicode-segmentation 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", ] -[[package]] -name = "strsim" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" - [[package]] name = "syn" version = "0.15.44" @@ -855,7 +849,6 @@ dependencies = [ "checksum serde_json 1.0.48 (registry+https://github.com/rust-lang/crates.io-index)" = "9371ade75d4c2d6cb154141b9752cf3781ec9c05e0e5cf35060e1e70ee7b9c25" "checksum shaman 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3b1a48b7e97a07b8f5771159e6914d8459557f8f833a60c4bd041f03736844f5" "checksum strcursor 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)" = "a53cb721e1f6d0dbba1296e2d7770edbec9a4888fdd8f6a22fea97a0a69b465a" -"checksum strsim 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a" "checksum syn 0.15.44 (registry+https://github.com/rust-lang/crates.io-index)" = "9ca4b3b69a77cbe1ffc9e198781b7acb0c7365a883670e8f1c1bc66fba79a5c5" "checksum syn 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "158521e6f544e7e3dcfc370ac180794aa38cb34a1b1e07609376d4adcf429b93" "checksum synstructure 0.10.2 (registry+https://github.com/rust-lang/crates.io-index)" = "02353edf96d6e4dc81aea2d8490a7e9db177bf8acb0e951c24940bf866cb313f" diff --git a/src/error.rs b/src/error.rs index 0e3aa855..c921858d 100644 --- a/src/error.rs +++ b/src/error.rs @@ -78,18 +78,7 @@ impl fmt::Display for MainError { } } -impl Error for MainError { - fn description(&self) -> &str { - use self::MainError::*; - match *self { - Io(_, ref err) => err.description(), - Tag(_, ref msg, _) => msg, - Other(_, ref err) => err.description(), - OtherOwned(_, ref err) => err, - OtherBorrowed(_, ref err) => err, - } - } -} +impl Error for MainError {} macro_rules! from_impl { ($src_ty:ty => $dst_ty:ty, $src:ident -> $e:expr) => { diff --git a/src/main.rs b/src/main.rs index 4c8eaa3a..c3aa19b4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -44,7 +44,6 @@ mod util; #[cfg(windows)] mod file_assoc; -use std::error::Error; use std::ffi::OsString; use std::fs; use std::io::{Read, Write}; @@ -456,7 +455,7 @@ fn clean_cache(max_age: u128) -> Result<()> { }; info!("meta_mtime: {:>20?} ms", meta_mtime); - (meta_mtime <= cutoff) + meta_mtime <= cutoff }; if remove_dir() { @@ -826,7 +825,7 @@ fn decide_action_for( Ok(meta) => meta, Err(err) => { info!("recompiling because: failed to load metadata"); - debug!("get_pkg_metadata error: {}", err.description()); + debug!("get_pkg_metadata error: {}", err); bail!(compile: true) } };