From ce6f987bdb6674a93260868478fc1bc95868c580 Mon Sep 17 00:00:00 2001 From: Michael Howell Date: Fri, 11 Mar 2022 16:21:31 -0700 Subject: [PATCH 1/3] Add regression test for `::count` Fixes #84495 --- src/test/ui/methods/issues/issue-84495.rs | 4 ++++ src/test/ui/methods/issues/issue-84495.stderr | 13 +++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 src/test/ui/methods/issues/issue-84495.rs create mode 100644 src/test/ui/methods/issues/issue-84495.stderr diff --git a/src/test/ui/methods/issues/issue-84495.rs b/src/test/ui/methods/issues/issue-84495.rs new file mode 100644 index 0000000000000..28c094bf2acd5 --- /dev/null +++ b/src/test/ui/methods/issues/issue-84495.rs @@ -0,0 +1,4 @@ +fn main() { + let x: i32 = 1; + println!("{:?}", x.count()); //~ ERROR is not an iterator +} diff --git a/src/test/ui/methods/issues/issue-84495.stderr b/src/test/ui/methods/issues/issue-84495.stderr new file mode 100644 index 0000000000000..b0217a7c844d7 --- /dev/null +++ b/src/test/ui/methods/issues/issue-84495.stderr @@ -0,0 +1,13 @@ +error[E0599]: `i32` is not an iterator + --> $DIR/issue-84495.rs:3:24 + | +LL | println!("{:?}", x.count()); + | ^^^^^ `i32` is not an iterator + | + = note: the following trait bounds were not satisfied: + `i32: Iterator` + which is required by `&mut i32: Iterator` + +error: aborting due to previous error + +For more information about this error, try `rustc --explain E0599`. From ad2ae5dbb272eeb9df950cc38ef9d958f6c1e353 Mon Sep 17 00:00:00 2001 From: Guillaume Gomez Date: Sat, 12 Mar 2022 16:07:42 +0100 Subject: [PATCH 2/3] Update browser-ui-test version used in CI --- src/ci/docker/host-x86_64/x86_64-gnu-tools/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ci/docker/host-x86_64/x86_64-gnu-tools/Dockerfile b/src/ci/docker/host-x86_64/x86_64-gnu-tools/Dockerfile index 9b92bed1f02b3..b0f052e6cf0d9 100644 --- a/src/ci/docker/host-x86_64/x86_64-gnu-tools/Dockerfile +++ b/src/ci/docker/host-x86_64/x86_64-gnu-tools/Dockerfile @@ -72,7 +72,7 @@ ENV PATH="/node-v14.4.0-linux-x64/bin:${PATH}" # https://github.com/puppeteer/puppeteer/issues/375 # # We also specify the version in case we need to update it to go around cache limitations. -RUN npm install -g browser-ui-test@0.8.0 --unsafe-perm=true +RUN npm install -g browser-ui-test@0.8.1 --unsafe-perm=true ENV RUST_CONFIGURE_ARGS \ --build=x86_64-unknown-linux-gnu \ From cc5cf86bfb22d8e9d2275c4e2f37a25c1a56c4a4 Mon Sep 17 00:00:00 2001 From: Noah Lev Date: Sat, 12 Mar 2022 13:00:12 -0800 Subject: [PATCH 3/3] Remove needless use of `Into` --- src/librustdoc/clean/inline.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/librustdoc/clean/inline.rs b/src/librustdoc/clean/inline.rs index 353df68443f6b..ec538f11831b0 100644 --- a/src/librustdoc/clean/inline.rs +++ b/src/librustdoc/clean/inline.rs @@ -327,7 +327,7 @@ fn merge_attrs( /// Inline an `impl`, inherent or of a trait. The `did` must be for an `impl`. crate fn build_impl( cx: &mut DocContext<'_>, - parent_module: impl Into>, + parent_module: Option, did: DefId, attrs: Option>, ret: &mut Vec, @@ -478,7 +478,7 @@ crate fn build_impl( record_extern_trait(cx, did); } - let (merged_attrs, cfg) = merge_attrs(cx, parent_module.into(), load_attrs(cx, did), attrs); + let (merged_attrs, cfg) = merge_attrs(cx, parent_module, load_attrs(cx, did), attrs); trace!("merged_attrs={:?}", merged_attrs); trace!(