From 0874ba0fe57e792fc21f835be33fbccc7f576787 Mon Sep 17 00:00:00 2001 From: Oliver Schneider Date: Mon, 21 May 2018 09:56:52 +0200 Subject: [PATCH] Typo caused the wrong "cannot find" error --- src/test/ui/impl-trait/universal_wrong_bounds.rs | 4 ++-- src/test/ui/impl-trait/universal_wrong_bounds.stderr | 11 ++--------- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/src/test/ui/impl-trait/universal_wrong_bounds.rs b/src/test/ui/impl-trait/universal_wrong_bounds.rs index a5e948223fb1..63d000c05683 100644 --- a/src/test/ui/impl-trait/universal_wrong_bounds.rs +++ b/src/test/ui/impl-trait/universal_wrong_bounds.rs @@ -13,12 +13,12 @@ use std::fmt::Display; fn foo(f: impl Display + Clone) -> String { wants_debug(f); wants_display(f); - wants_clone(f); //~ ERROR cannot find + wants_clone(f); } fn wants_debug(g: impl Debug) { } //~ ERROR cannot find fn wants_display(g: impl Debug) { } //~ ERROR cannot find -fn wants_cone(g: impl Clone) { } +fn wants_clone(g: impl Clone) { } fn main() { } diff --git a/src/test/ui/impl-trait/universal_wrong_bounds.stderr b/src/test/ui/impl-trait/universal_wrong_bounds.stderr index 02ac4707bc55..68a318e2ac4b 100644 --- a/src/test/ui/impl-trait/universal_wrong_bounds.stderr +++ b/src/test/ui/impl-trait/universal_wrong_bounds.stderr @@ -1,9 +1,3 @@ -error[E0425]: cannot find function `wants_clone` in this scope - --> $DIR/universal_wrong_bounds.rs:16:5 - | -LL | wants_clone(f); //~ ERROR cannot find - | ^^^^^^^^^^^ did you mean `wants_cone`? - error[E0405]: cannot find trait `Debug` in this scope --> $DIR/universal_wrong_bounds.rs:19:24 | @@ -24,7 +18,6 @@ help: possible candidate is found in another module, you can import it into scop LL | use std::fmt::Debug; | -error: aborting due to 3 previous errors +error: aborting due to 2 previous errors -Some errors occurred: E0405, E0425. -For more information about an error, try `rustc --explain E0405`. +For more information about this error, try `rustc --explain E0405`.