about summary refs log tree commit diff
path: root/tests/ui/impl-trait/trait_upcasting_reference_mismatch.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/impl-trait/trait_upcasting_reference_mismatch.stderr')
-rw-r--r--tests/ui/impl-trait/trait_upcasting_reference_mismatch.stderr9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/ui/impl-trait/trait_upcasting_reference_mismatch.stderr b/tests/ui/impl-trait/trait_upcasting_reference_mismatch.stderr
new file mode 100644
index 00000000000..92da47b08e9
--- /dev/null
+++ b/tests/ui/impl-trait/trait_upcasting_reference_mismatch.stderr
@@ -0,0 +1,9 @@
+error[E0282]: type annotations needed
+  --> $DIR/trait_upcasting_reference_mismatch.rs:7:35
+   |
+LL | fn hello() -> &'static (dyn Trait<impl Sized> + Send) {
+   |                                   ^^^^^^^^^^ cannot infer type
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0282`.