summaryrefslogtreecommitdiffstats
path: root/tests/ui/fully-qualified-type/fully-qualified-type-name2.rs
blob: f26d3be66303df6d7d75ab40daec9574c54da28b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Test that we use fully-qualified type names in error messages.

mod x {
    pub enum Foo { }
}

mod y {
    pub enum Foo { }
}

fn bar(x: x::Foo) -> y::Foo {
    return x;
    //~^ ERROR mismatched types
    //~| expected `y::Foo`, found `x::Foo`
}

fn main() {
}