diff options
Diffstat (limited to 'src/test/ui/impl-trait/universal-mismatched-type.stderr')
-rw-r--r-- | src/test/ui/impl-trait/universal-mismatched-type.stderr | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/test/ui/impl-trait/universal-mismatched-type.stderr b/src/test/ui/impl-trait/universal-mismatched-type.stderr new file mode 100644 index 000000000..817c573c0 --- /dev/null +++ b/src/test/ui/impl-trait/universal-mismatched-type.stderr @@ -0,0 +1,16 @@ +error[E0308]: mismatched types + --> $DIR/universal-mismatched-type.rs:4:5 + | +LL | fn foo(x: impl Debug) -> String { + | ---------- ------ expected `String` because of return type + | | + | this type parameter +LL | x + | ^ expected struct `String`, found type parameter `impl Debug` + | + = note: expected struct `String` + found type parameter `impl Debug` + +error: aborting due to previous error + +For more information about this error, try `rustc --explain E0308`. |