From 8c48b8ae92bf10a4c578ec2181ac28a675c396f9 Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Thu, 15 Jul 2021 16:43:41 +0900 Subject: [PATCH 1/5] Rustup to rust-lang/rust#86749 --- rust-toolchain | 2 +- src/bin/rust-semver-public.rs | 2 +- src/bin/rust-semverver.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/rust-toolchain b/rust-toolchain index 65ecb94b..83e2430d 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -1,4 +1,4 @@ # NOTE: Keep in sync with nightly date on README [toolchain] -channel = "nightly-2021-06-14" +channel = "nightly-2021-07-03" components = ["llvm-tools-preview", "rustc-dev"] diff --git a/src/bin/rust-semver-public.rs b/src/bin/rust-semver-public.rs index 8fe1dd2a..d49765dd 100644 --- a/src/bin/rust-semver-public.rs +++ b/src/bin/rust-semver-public.rs @@ -39,7 +39,7 @@ fn main() { queries.global_ctxt().unwrap().peek_mut().enter(|tcx| { let krate = tcx - .crates() + .crates(()) .iter() .flat_map(|crate_num| { let def_id = crate_num.as_def_id(); diff --git a/src/bin/rust-semverver.rs b/src/bin/rust-semverver.rs index 559c9e2c..6dee1ef3 100644 --- a/src/bin/rust-semverver.rs +++ b/src/bin/rust-semverver.rs @@ -57,7 +57,7 @@ fn main() { // See issue #64 for details. let mut crates: Vec<_> = tcx - .crates() + .crates(()) .iter() .flat_map(|crate_num| { let def_id = crate_num.as_def_id(); From 251d0f193de02b3a96e1c8755fb6b96aec0257bb Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Thu, 15 Jul 2021 16:48:19 +0900 Subject: [PATCH 2/5] Rustup to rust-lang/rust#84961 --- rust-toolchain | 2 +- src/changes.rs | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/rust-toolchain b/rust-toolchain index 83e2430d..f4820aea 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -1,4 +1,4 @@ # NOTE: Keep in sync with nightly date on README [toolchain] -channel = "nightly-2021-07-03" +channel = "nightly-2021-07-15" components = ["llvm-tools-preview", "rustc-dev"] diff --git a/src/changes.rs b/src/changes.rs index a8bfb1c3..d9683fa9 100644 --- a/src/changes.rs +++ b/src/changes.rs @@ -1488,7 +1488,7 @@ pub mod tests { quickcheck! { /// The `Ord` instance of `PathChange` is transitive. fn ord_pchange_transitive(c1: PathChange_, c2: PathChange_, c3: PathChange_) -> bool { - rustc_span::with_default_session_globals(|| { + rustc_span::create_default_session_globals_then(|| { let s1 = c1.2.iter().map(|&(add, ref s)| (add, s.clone().inner())).collect(); let s2 = c2.2.iter().map(|&(add, ref s)| (add, s.clone().inner())).collect(); let s3 = c3.2.iter().map(|&(add, ref s)| (add, s.clone().inner())).collect(); @@ -1517,7 +1517,7 @@ pub mod tests { /// The `Ord` instance of `Change` is transitive. fn ord_change_transitive(c1: Change_, c2: Change_, c3: Change_) -> bool { - rustc_span::with_default_session_globals(|| { + rustc_span::create_default_session_globals_then(|| { let ch1 = build_change(c1.3.inner(), c1.4, c1.5); let ch2 = build_change(c2.3.inner(), c2.4, c2.5); let ch3 = build_change(c3.3.inner(), c3.4, c3.5); @@ -1543,7 +1543,7 @@ pub mod tests { /// The maximal change category for a change set with regular changes only gets computed /// correctly. fn max_pchange(changes: Vec) -> bool { - rustc_span::with_default_session_globals(|| { + rustc_span::create_default_session_globals_then(|| { let mut set = ChangeSet::default(); let mut interner = Interner::default(); @@ -1576,7 +1576,7 @@ pub mod tests { /// The maximal change category for a change set with path changes only gets computed /// correctly. fn max_change(changes: Vec) -> bool { - rustc_span::with_default_session_globals(|| { + rustc_span::create_default_session_globals_then(|| { let mut set = ChangeSet::default(); let mut interner = Interner::default(); @@ -1611,7 +1611,7 @@ pub mod tests { } fn max_pchange_or_change(pchanges: Vec, changes: Vec) -> bool { - rustc_span::with_default_session_globals(|| { + rustc_span::create_default_session_globals_then(|| { let mut set = ChangeSet::default(); let mut interner = Interner::default(); @@ -1664,7 +1664,7 @@ pub mod tests { /// Difference in spans implies difference in `PathChange`s. fn pchange_span_neq(c1: PathChange_, c2: PathChange_) -> bool { - rustc_span::with_default_session_globals(|| { + rustc_span::create_default_session_globals_then(|| { let v1 = c1.2.iter().map(|&(add, ref s)| (add, s.clone().inner())).collect(); let v2 = c2.2.iter().map(|&(add, ref s)| (add, s.clone().inner())).collect(); @@ -1684,7 +1684,7 @@ pub mod tests { /// Difference in spans implies difference in `Change`s. fn bchange_span_neq(c1: Change_, c2: Change_) -> bool { - rustc_span::with_default_session_globals(|| { + rustc_span::create_default_session_globals_then(|| { let s1 = c1.3.clone().inner(); let s2 = c2.3.clone().inner(); From bc21ea7b49bfb4c36ded5adbda4257ccd62070ea Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Thu, 15 Jul 2021 16:50:26 +0900 Subject: [PATCH 3/5] Fix a clippy warning --- src/bin/cargo-semver.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/cargo-semver.rs b/src/bin/cargo-semver.rs index aea1f192..b7532ec8 100644 --- a/src/bin/cargo-semver.rs +++ b/src/bin/cargo-semver.rs @@ -496,7 +496,7 @@ impl<'a> WorkInfo<'a> { opts.cli_features.features = Rc::new( s.split(' ') .map(InternedString::new) - .map(|f| FeatureValue::new(f)) + .map(FeatureValue::new) .collect(), ); } From 19df0b0327f6c989d7a2335d660047c89950bdff Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Thu, 15 Jul 2021 16:55:45 +0900 Subject: [PATCH 4/5] Update docs --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 8ba78716..fe5f4e80 100644 --- a/README.md +++ b/README.md @@ -27,13 +27,13 @@ repository and compiled from source or installed from of the nightly toolchain is supported at any given time. -It's recommended to use `nightly-2021-06-14` toolchain. -You can install it by using `rustup install nightly-2021-06-14` if you already have rustup. +It's recommended to use `nightly-2021-07-15` toolchain. +You can install it by using `rustup install nightly-2021-07-15` if you already have rustup. Then you can do: ```sh -$ rustup component add rustc-dev llvm-tools-preview --toolchain nightly-2021-06-14 -$ cargo +nightly-2021-06-14 install --git https://github.com/rust-lang/rust-semverver +$ rustup component add rustc-dev llvm-tools-preview --toolchain nightly-2021-07-15 +$ cargo +nightly-2021-07-15 install --git https://github.com/rust-lang/rust-semverver ``` You'd also need `cmake` for some dependencies, and a few common libraries (if you hit From 863b40ea908d9506ec9e859532f612a84f95a1f8 Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Sat, 24 Jul 2021 05:32:00 +0900 Subject: [PATCH 5/5] Rustup to nightly-2021-07-23 --- README.md | 8 ++++---- rust-toolchain | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index fe5f4e80..e91b5bbb 100644 --- a/README.md +++ b/README.md @@ -27,13 +27,13 @@ repository and compiled from source or installed from of the nightly toolchain is supported at any given time. -It's recommended to use `nightly-2021-07-15` toolchain. -You can install it by using `rustup install nightly-2021-07-15` if you already have rustup. +It's recommended to use `nightly-2021-07-23` toolchain. +You can install it by using `rustup install nightly-2021-07-23` if you already have rustup. Then you can do: ```sh -$ rustup component add rustc-dev llvm-tools-preview --toolchain nightly-2021-07-15 -$ cargo +nightly-2021-07-15 install --git https://github.com/rust-lang/rust-semverver +$ rustup component add rustc-dev llvm-tools-preview --toolchain nightly-2021-07-23 +$ cargo +nightly-2021-07-23 install --git https://github.com/rust-lang/rust-semverver ``` You'd also need `cmake` for some dependencies, and a few common libraries (if you hit diff --git a/rust-toolchain b/rust-toolchain index f4820aea..13425aba 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -1,4 +1,4 @@ # NOTE: Keep in sync with nightly date on README [toolchain] -channel = "nightly-2021-07-15" +channel = "nightly-2021-07-23" components = ["llvm-tools-preview", "rustc-dev"]