]> git.proxmox.com Git - rustc.git/blobdiff - src/test/ui/type-alias-impl-trait/declared_but_not_defined_in_scope.stderr
New upstream version 1.48.0~beta.8+dfsg1
[rustc.git] / src / test / ui / type-alias-impl-trait / declared_but_not_defined_in_scope.stderr
index c0cb94b15d033135ca3af397b52eac6c922ac320..0b4c262bbb43b97f0a52e7bb8d9a60cc75a83d2c 100644 (file)
@@ -4,5 +4,20 @@ error: could not find defining uses
 LL |     pub type Boo = impl ::std::fmt::Debug;
    |                    ^^^^^^^^^^^^^^^^^^^^^^
 
-error: aborting due to previous error
+error[E0308]: mismatched types
+  --> $DIR/declared_but_not_defined_in_scope.rs:11:5
+   |
+LL |     pub type Boo = impl ::std::fmt::Debug;
+   |                    ---------------------- the expected opaque type
+...
+LL | fn bomp() -> boo::Boo {
+   |              -------- expected `impl Debug` because of return type
+LL |     ""
+   |     ^^ expected opaque type, found `&str`
+   |
+   = note: expected opaque type `impl Debug`
+                found reference `&'static str`
+
+error: aborting due to 2 previous errors
 
+For more information about this error, try `rustc --explain E0308`.