]> git.lizzy.rs Git - rust.git/blob - src/test/ui/fully-qualified-type/fully-qualified-type-name2.rs
Rollup merge of #61207 - taiki-e:arbitrary_self_types-lifetime-elision-2, r=Centril
[rust.git] / src / test / ui / fully-qualified-type / fully-qualified-type-name2.rs
1 // Test that we use fully-qualified type names in error messages.
2
3 mod x {
4     pub enum Foo { }
5 }
6
7 mod y {
8     pub enum Foo { }
9 }
10
11 fn bar(x: x::Foo) -> y::Foo {
12     return x;
13     //~^ ERROR mismatched types
14     //~| expected type `y::Foo`
15     //~| found type `x::Foo`
16     //~| expected enum `y::Foo`, found enum `x::Foo`
17 }
18
19 fn main() {
20 }