bump rustc-semver version. use in built method to compare versions

This commit is contained in:
Suyash458 2020-11-30 11:24:10 +05:30
parent 61b29281e7
commit e7258ac714
2 changed files with 2 additions and 2 deletions

View File

@ -28,7 +28,7 @@ smallvec = { version = "1", features = ["union"] }
toml = "0.5.3"
unicode-normalization = "0.1"
semver = "0.11"
rustc-semver="1.0.0"
rustc-semver="1.1.0"
# NOTE: cargo requires serde feat in its url dep
# see <https://github.com/rust-lang/rust/pull/63587#issuecomment-522343864>
url = { version = "2.1.0", features = ["serde"] }

View File

@ -76,7 +76,7 @@ pub fn parse_msrv(msrv: &str, sess: Option<&Session>, span: Option<Span>) -> Opt
}
pub fn meets_msrv(msrv: Option<&RustcVersion>, lint_msrv: &RustcVersion) -> bool {
msrv.map_or(true, |msrv| msrv >= lint_msrv)
msrv.map_or(true, |msrv| msrv.meets(*lint_msrv))
}
macro_rules! extract_msrv_attr {